Skip to content

Instantly share code, notes, and snippets.

@fmap
Last active August 29, 2015 14:02
Show Gist options
  • Save fmap/7c723ae61708c1e93386 to your computer and use it in GitHub Desktop.
Save fmap/7c723ae61708c1e93386 to your computer and use it in GitHub Desktop.
import Control.Monad (liftM2)
import Control.Arrow (Arrow((&&&)), (>>>), (<<<))
(>>|) :: Arrow a => a b c -> a c d -> a b (c,d)
(>>|) = liftM2 (<<<) (&&&) (>>>)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment