The map, filter, and reduce functions

Swift provides map, filter, and reduce functions, which are higher-order functions.