There’s a chance you’ve heard a term floating around with some of the more functional-minded languages. The term is “curry” and not only is it a delicious Southeastern Asian cuisine, it also refers to translating the evaluation of a function that takes multiple arguments into evaluating a sequence of functions, each with a single argument. Obviously.
Let’s take a quick walk through the world of function currying in Swift, figure out what that nonsense above really means, and then see how we could use this technique in the real world.
Read more on robots.thoughtbot.com