8.5 Analysis
Higher-order functions capture common, typically recursive, programming patterns as functions. When HOFs are curried, they can be used to automatically define atomic functions—rendering the HOFs more powerful. Curried HOFs help programmers define functions in a modular, succinct, and easily modifiable/reconfigurable fashion. They provide the glue that enables these atomic functions to be combined to construct more complex functions, as the examples in the prior section demonstrate. The use of curried HOFs lifts us to a higher-order style of functional programming—the third tier of functional programming in Figure 5.10. In this style of programming, programs are composed of a series of concise function definitions that are defined ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access