3 ms·
Yes, it is perfectly readable. But: there is a function returning a function. Haskell just decided to have a syntax (and type system) that can handle this wit
by eru 4y ago
Yes, it is perfectly readable. But: there is a function returning a function.
Haskell just decided to have a syntax (and type system) that can handle this without inducing nausea in the programmer.
As with everything, this comes with trade-offs. For example, Haskell's syntax (and type system) have a much harder time dealing with optional arguments. Something that eg Python does just fine, and that even C handles OK in the form of varargs.