Hacker News new | past | comments | ask | show | jobs | submit login

Why are Monads considered difficult?



They are difficult because the concept is very unfamiliar and abstract. It's also not very easy to see the motivation at first.


Perhaps I am too tainted.

Monads can be motivated as a generalization of a lot of stuff that follows similar rules (the Monad laws). E.g. Lists, Haskell's Maybe (representing success/failure), sequential computation.


As a Haskell beginner it's not so easy to see the generalization between State, Maybe, IO, and especially Lists.

This is exactly the problem.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: