Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

map & filter

const filteredList = watchList.map(movie => ({
  title : movie['Title'],
  rating: movie["imdbRating"]
})
).filter(movie => {
  return parseFloat(movie.rating) >= 8.0;
})
 
PREVIOUS NEXT
Tagged: #map #filter
ADD COMMENT
Topic
Name
4+3 =