Re:Monads are a Class of Hard Drugs (2008)
by fusiongyro on Sunday December 30, 2012 @09:45AM
(#4985791)
I think we're on the same page not seeing a real use for them. :)
It's just so weird, because monads are obviously useful :)
Re:Monads are a Class of Hard Drugs (2008)
by fusiongyro on Tuesday January 01, 2013 @11:02PM
(#4995260)
If they're meant to be, somebody will cook up a few great instances and show why monads and other abstractions were insufficient. Until that happens I don't think they need to be in people's standard repertoire. Applicative functors seem to be much more handy.
I'd like to know more about comonads too, but the only interesting article I've seen about them I can recall was this one about using comonads to build a zipper for managing location in a site menu.
http://fmapfixreturn.wordpress.com/2008/07/09/comonads-in-ev...
Your post was very clear (although your code blocks have a tiny font on my computer for some reason). The &&& and >>> combinators make sense, especially with your diagram... but in the fizzbuzz case I don't get why it's preferable to have the arrow over something like
Although maybe it's just a case of making it simple to compose functions when there are tens of inputs or something, so the simple case wouldn't really demonstrate anything like that.