3 ms·
Haskell per se doesn't really have monads, except in the sense that there's an opaque `IO` type which is only useful for "doing IO" because it is an instance of
by jberryman 11y ago
Haskell per se doesn't really have monads, except in the sense that there's an opaque `IO` type which is only useful for "doing IO" because it is an instance of `Monad` (and `Functor`), and in the sense that there's some very thin syntactic sugar for composing monadic types. So haskell-the-language has type classes (like `Monad` or `Functor` or `Show`), and more importantly strong static typing. The latter means you can create abstractions (like Monad) that are not brittle.
You can check out this module:
http://hackage.haskell.org/package/base-4.8.1.0/docs/Control-Monad.html http://hackage.haskell.org/package/base-4.8.1.0/docs/Control...
You can see all the varied sorts of things which are "instances of Monad", then scroll beyond and see all these different useful operations which behave sensibly for all those different instances (and from which you can build your own more complex operations which work for any Monad, and which also behave sensibly).