fork download
  1. import Control.Arrow
  2. import Control.Monad
  3. import Control.Monad.Instances
  4.  
  5. square = join (*)
  6. biApply = join (***)
  7.  
  8. foo = ((uncurry (+) . biApply square) .) . (,)
  9.  
  10. main = print $ foo 3 4
Success #stdin #stdout 0.01s 3588KB
stdin
Standard input is empty
stdout
25