back

by danieltanfh95·5y ago·view on hn ↗
https://medium.com/glassblade/pragmatic-monad-understanding-...

Try this instead, simply put monads are used to provide an easier to use API to some black box abstraction. Example monads can include a "List" or a "Class"

Why does Haskell etc need this? because its hard for them to make an easier to use API to access the internals of some abstraction due to the strict type system unless they use the monad pattern. In comparison in untyped FP everything is transparent while OOP allows you to create your own API within the abstraction itself.

Funnily enough from this thread you can see all sorts of wrong ideas about Monads that beginner Haskellers have

1 comments
Thanks! I can almost wrap my head around it now.