fix(curriculum): update object keys referenced in instructions to match provided object (#42613)
* Update referenced object keys for clarity Because each movie object has both `Rated` and `imdbRating` key/value pairs, simply referencing `rating` could be confusing to campers. IMO explicitly referencing the keys by name (`Title` and `imdbRating`) removes ambiguity in the non-important part of this challenge and helps campers focus on learning about `.map()`. * other references and tests * Update curriculum/challenges/english/02-javascript-algorithms-and-data-structures/functional-programming/use-the-map-method-to-extract-data-from-an-array.md * reverse previous changes * Update curriculum/challenges/english/02-javascript-algorithms-and-data-structures/functional-programming/use-the-map-method-to-extract-data-from-an-array.md Co-authored-by: Shaun Hamilton <shauhami020@gmail.com> Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>pull/42661/head
parent
adc09ec180
commit
6631e51113
|
@ -37,7 +37,7 @@ The console would display the value ` [ 'John', 'Amy', 'camperCat' ]`.
|
|||
|
||||
# --instructions--
|
||||
|
||||
The `watchList` array holds objects with information on several movies. Use `map` on `watchList` to assign a new array of objects with only `title` and `rating` keys to the `ratings` variable. The code in the editor currently uses a `for` loop to do this, so you should replace the loop functionality with your `map` expression.
|
||||
The `watchList` array holds objects with information on several movies. Use `map` on `watchList` to assign a new array of objects to the `ratings` variable. Each movie in the new array should have only a `title` key with the name of the film, and a `rating` key with the IMDB rating. The code in the editor currently uses a `for` loop to do this, so you should replace the loop functionality with your `map` expression.
|
||||
|
||||
# --hints--
|
||||
|
||||
|
|
Loading…
Reference in New Issue