I’ve been through phases when I could explain it, and in far simpler terms, less jargony, than endofunctors
A monad is when you can do shit and return stuff. There are two things you can do in absolutely every doShitAndReturnStuff:
andThen, also known as;in less flexible languages and>=in more esoteric languages.- And
returnalso known as
function ret(const a)
{ ret = a
}in other languages.
There are two rules:
(a then b) then c=a then (b then c), which sounds obvious, but I skipped a couple of values being passed (I’m using the kleisli category), and it can actually go wrong, which means that if you don’t have a monad but behave like you do, all sorts of subtle and very hard indeed to debug errors can sneak in. See “software complexity problem” for details.ret then somethingrother=somethingorother=somethingorother then ret, which would seem obvious to you if you spotted that ret does nothing, but for fun, it turns out that in a language with a sufficiently advanced/flexible/accurate type system (eg Hindley-Milner stuff), of you manage 2 you get 1 for free, which is totally awesome.
“But what’s the point?” I hear all the Python devs say “We already got rid of the curly brackets. What more do you want?” (Which starts a flame war with the C syntax folk while the elm programmers shake their head and wonder why anyone is manually formatting their code whether it’s with curly braces or not in 2026).
Well, the point, my dear internet Lunatics that have persisted with this fairly unhelpful and daft re-expression of monads, the point is: what if you could redefine ; locally to totally rewire your programming language and everyone was used to that and understood what you were doing from context? Yesterday it was making database requests, but today it’s answering queries on a server. Or authenticating users from the other side of the globe. Maybe now it’s a recursive descent parser or a non-deterministic, expanding list of possible future moves in a game.
It’s totally awesome and powerful and you just don’t know that you’re missing it because you have no idea unless you already know, but that’s not really helping anyone that doesn’t already understand monads, sorry. Not that this was a plausible attempt at that. It’s more just a bit of humour if you already came across monads. Famously a monad is like a burrito more than anything else.
But unfortunately there are also monad transformer stacks. And… …operator soup for lenses and prisms. And trust me, you don’t want to go there, you really, really don’t. Just don’t go there, I’m telling you, don’t. DID YOU LIKE BEING SANE? I WARNED YOU, REMEMBER.









elm is easily the loveliest programming language of any paradigm I’ve ever come across. Imagine if you enjoyed maintaining an old codebase, or that five years later adding a new feature wouldn’t take you half a day to get your had round the insane tangled spaghetti of your project, because the spaghetti and the meatballs and the sauce were always kept separate until cooked and served on the dish by the compiler. You find the spaghetti straight and in bundles because that’s how you like them laid out and no one tried to get you to soften them in the warm sauce and thread them through the raw meatballs. Imagine if the compiler did your whole project in about three to five seconds, and was genuinely helpful when something is going to bite you later.
Get your monad burritos here: https://byorgey.wordpress.com/2009/01/12/abstraction-intuition-and-the-monad-tutorial-fallacy/