Duration
1 min
Access
Pro
Transcript
Available

This lesson teaches the concept of higher order functions (HOF) in JavaScript, a necessary building block of functional programming in any language.

A higher order function does at least one of the following things, often both:

  1. Accepts a function as an argument
  2. Returns a new function

To demonstrate this, we will build a higher order function, withCount(), that modifies any function passed to it so that it logs out how many times it has been called.