Newbie qustion about monads

Alastair Reid alastair at
Thu Oct 2 23:28:31 EDT 2003

> As Derek has
> pointed out, I'm yet far from reaching a point where I should worry
> about that :)

_If_ you understand Haskell but not monads, I think it is entirely legitimate 
to start with the implementation and then proceed to the uses.  A bottom-up 
approach instead of a top-down approach.

This is the approach of Will Partain's old 'country boys guide to 
monads' (which I can't find a copy of).  He started with examples of 
non-monadic code where you couldn't see what was going on because of all the 
'plumbing' required to make sure you had a supply of fresh names here and a 
current substitution there and showed how a monad could cleanup the plumbing.

Of course, this only works if you've written enough of the right kind of code 
that the examples make sense...

Alastair Reid

More information about the Haskell-Cafe mailing list