array using splits example fix

to avoid using already defined text property definition
pull/23/head
Patrick Njuguna 6 years ago committed by GitHub
parent d16e82245a
commit 8ec8b3650b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -137,9 +137,9 @@ let companiesString = 'Facebook, Google, Microsoft, Apple, IBM, Oracle, Amazon'
const companies = companiesString.split(',')
console.log(companies) // ["Facebook", " Google", " Microsoft", " Apple", " IBM", " Oracle", " Amazon"]
let text =
let txt =
'I love teaching and empowering people. I teach HTML, CSS, JS, React, Python.'
const words = text.split(' ')
const words = txt.split(' ')
console.log(words)
// the text has special characters think how you can just get only the words
@ -721,4 +721,4 @@ const webTechs = [
🎉 CONGRATULATIONS ! 🎉
[<< Day 4](https://github.com/Asabeneh/30DaysOfJavaScript/blob/master/04_Day/04_day_conditionals.md) | [Day 6 >>](#)
[<< Day 4](https://github.com/Asabeneh/30DaysOfJavaScript/blob/master/04_Day/04_day_conditionals.md) | [Day 6 >>](#)

Loading…
Cancel
Save