4 ms·
It's a monad tutorial that's too embarrassed to admit it.
by bbcbasic 10y ago
It's a monad tutorial that's too embarrassed to admit it.
- edgyswingset 10y agoNo it's not. This is a tutorial on error handling that happens to be monadic. The emphasis is on handling errors, not talking about monads.
- bbcbasic 10y agoIt can be more than one thing at a time.
- edgyswingset 10y agoEmphasis mine: > It's a monad tutorial that's too embarrassed to admit it. This is not a correct interpretation of the blog post. This is not a monad tutorial, this is a tutorial on error handling that happens to be monadic.
- justinpombrio 10y ago> This is not a monad tutorial, this is a tutorial on error handling that happens to be monadic. And is, for that very reason, a great tutorial on monads, even if it's not a monad tutorial.
- signa11 10y ago> It's a monad tutorial... this would be closer to Haskell arrows than monads no ?
- marcosdumay 10y agoThis is one of the tutorials that made monads click for me (the other was the actual explanation at Learn You a Haskell). It's the Either monad, plain and simple.
- Roboprog 10y agoAnd here I was thinking it's about a practice of returning & accepting a tuple of ( primary-result xor dead-already-cuz ) and morphing the (primary) result type as the "f * g * h of x" pipeline cascades.
- piaste 10y agoHighly relevant: https://fsharpforfunandprofit.com/about/#banned https://fsharpforfunandprofit.com/about/#banned Seriously! As I make clear on the home page, this site is not targeted at mathematicians or Haskell programmers. It is targeted at the vast numbers of C#, VB and Python programmers who are coming to functional programming for the first time. F# is a fantastically accessible language for the average enterprise programmer, but mathematical jargon puts a lot of people off ("a monad is a monoid in the category of endofunctors, what's the problem?"), and I think it is much better to explain F# with concepts from within its native environment, rather than using terminology that originated elsewhere and is often not applicable. For example, treating F# computation expressions like Haskell monads can often make things more confusing. Doing this also helps to bypass the "how can you get anything done in language X? It doesn't even have y." debate and focus on what F# can do well.
- bbcbasic 10y agoYes. On the opposite end of the spectrum is any Reddit answer or blog post by Edward Kmett but I for some reason I love reading his answers even if I have no idea what he is talking about! However his audience would be advanced Haskellers or researchers.