map example fix

I am not sure what the intention was with the countyCode code, but to get the output in the example, it should be written this way
pull/47/head
Patrick Njuguna 6 years ago committed by GitHub
parent 6adedd1b7b
commit 1343701313
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -241,9 +241,7 @@ const countries = [
'Kenya'
]
const countriesToUpperCase = countries.map(function(country){
let countryCode = country.toUpperCase().slice(0, 3)
let country = country.length
return []
return country.toUpperCase();
})
console.log(countriesToUpperCase)
// ['ALBANIA', 'BOLIVIA', 'CANADA', 'DENMARK', 'ETHIOPIA', 'FINLAND', 'GERMANY', 'HUNGARY', 'IRELAND', 'JAPAN', 'KENYA']
@ -581,4 +579,4 @@ console.log(users); // sorted ascending
🎉 CONGRATULATIONS ! 🎉
[<< Day 8](https://github.com/Asabeneh/30DaysOfJavaScript/blob/master/08_Day/08_day_objects.md) | [Day 10 >>](#)
[<< Day 8](https://github.com/Asabeneh/30DaysOfJavaScript/blob/master/08_Day/08_day_objects.md) | [Day 10 >>](#)

Loading…
Cancel
Save