[Haskell-cafe] Are there arithmetic composition of functions?

Felipe Almeida Lessa felipe.lessa at gmail.com
Mon Mar 19 18:24:13 CET 2012


import Control.Applicative

f, g :: Float -> Float
f x = x + 1
g x = 2 * x

h = (+) <$> f <*> g


Cheers, =)

-- 
Felipe.



More information about the Haskell-Cafe mailing list