# HG changeset patch # User HackBot # Date 1357952538 0 # Node ID b2da99b2e4e092b7715432308417130bd6fd6801 # Parent 0c2527f959bee3fef77ba2b3f38b74fefb690aa2 mv wisdom/monad_tutorials wisdom/monad-tutorials diff -r 0c2527f959be -r b2da99b2e4e0 wisdom/monad-tutorials --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/wisdom/monad-tutorials Sat Jan 12 01:02:18 2013 +0000 @@ -0,0 +1,8 @@ +Monads are a bucket brigade with project managers. +Monads are like burritos. +Think of a monad as a spacesuite full of nuclear waste in the ocean next to a container of apples. now, you can't put oranges in the space suite or the nucelar waste falls in the ocean, but the apples are carried around anyway, and you just take what you need. +All space stations must put their astronauts into space suits before sending them out. +Monads are just monoids in the category of endofunctors. +Monads are like when you and a friend are trying to have a conversation about a mutual friend. +Monads are like overloading the semicolon. +class Monad m where ; (>>=) :: forall a b. m a -> (a -> m b) -> m b ; (>>) :: forall a b. m a -> m b -> m b ; return :: a -> m a ; fail :: String -> m a diff -r 0c2527f959be -r b2da99b2e4e0 wisdom/monad_tutorials --- a/wisdom/monad_tutorials Sat Jan 12 01:01:55 2013 +0000 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,8 +0,0 @@ -Monads are a bucket brigade with project managers. -Monads are like burritos. -Think of a monad as a spacesuite full of nuclear waste in the ocean next to a container of apples. now, you can't put oranges in the space suite or the nucelar waste falls in the ocean, but the apples are carried around anyway, and you just take what you need. -All space stations must put their astronauts into space suits before sending them out. -Monads are just monoids in the category of endofunctors. -Monads are like when you and a friend are trying to have a conversation about a mutual friend. -Monads are like overloading the semicolon. -class Monad m where ; (>>=) :: forall a b. m a -> (a -> m b) -> m b ; (>>) :: forall a b. m a -> m b -> m b ; return :: a -> m a ; fail :: String -> m a