- [Instructor] The next important built-in array function … is called Filter. … Filter is used when you want to find … all of the elements in an array … that fit some kind of criteria. … For example if we have an array of numbers … and we want to get all the numbers from it that are even, … or if we have an array of employee data, … and want to find the employees from this array … that make more than a certain amount per year. … These are the things that Filter can help us with. … The syntax to Filter is similar to Map. … We can call it on any array and then we pass in a function. … The main difference between Filter and Map is the type … of function that we pass into it. … In Map, we pass in a function that returns … a value for each element in the array. … And the return value of this function represents … what the element becomes in our new array. … On the other hand, for Filter, we pass it a function … that returns either true or false for each element. … If the function that we pass returns true …
- The goal of functional programming
- Declarative vs. imperative programming
- Ensuring immutability
- Arrow functions in ES6
- Passing functions as arguments
- Mapping, filtering, slicing, sorting, and reducing
- Advanced functional concepts, including recursion
Skill Level Intermediate
1. Introductory Functional Concepts
2. First-Class Functions
4. Advanced Functional Concepts
5. Code Conversion Challenges
Next steps1m 10s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.