Higher-order function

Higher-order function #

This chapter covers an essential feature of functional languages: a function can take a function as argument and/or return a function. This enables currying, and is often paired with the usage of anonymous functions (both borrowed from lambda calculus).

We will illustrate these notions in Haskell, and how they have made their way to Java.