3 ms·
Monads are easy. What’s hard is higher-order functions, parametric polymorphism, and ad-hoc polymorphism via typeclasses. Understanding any one of these is har
by massysett 2y ago
Monads are easy.
What’s hard is higher-order functions, parametric polymorphism, and ad-hoc polymorphism via typeclasses. Understanding any one of these is hard. Understanding all three is harder. Understanding all three applied simultaneously is harder still. That’s what monads are.
On top of all that, understanding “monads” doesn’t mean too much. IO does something, Maybe does something else, StateT something else.
But once you understand all that, monads are easy. Maybe monad analogies helped somebody understand all that, but they didn’t help me.
- MarkMarine 2y agoThis should be a blog post :) Tongue in cheek but seriously, I was pretty happy with my working understanding of monads and now I’m questioning it. Would love to hear you elaborate or link references so I can learn more