[Haskell-beginners] Question on evaluating function compostion

Roman Czyborra roman at czyborra.com
Wed Aug 20 10:47:16 UTC 2014


> Does (f . g) x y z equal ((((f . g) x) y) z)  in haskell?
>

Yes: (f . g) x y z = (((f (g (x)) (y)) (z)) = f (g x) y z since in Haskell
as a higher-order functional language a bare function mentioned to the left
is supposed to bind its argument stronger first before any lower-order
arguments are allowed to start acting rightwards.  (did-not (have
(this-readability-problem)) lisp)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/beginners/attachments/20140820/6905df53/attachment.html>


More information about the Beginners mailing list