Santa's Flight Computer

A literate Haskell Christmas story of monads and monad transformers... Wait, what?

Publish
Reading time
~1 min read

This was the final project for the functional programming course during my Computer Science (CS) master's.

The assignment: explore a topic not covered in class.
I chose "monad transformers".

A monad?! Yes, choose your own tutorial (opens in a new tab).
A transformer?! Layer monads like an onion.

It introduces the Reader, State, Writer, and Except monads separately.
Then, it combines them into a monad transformer stack for Santa's new flight computer.

Does it illustrate the concept of "monad transformers" well? Maybe.
The entirety of the concept came to me almost instantly, but then I spent a lot more time (way too much) on the narrative. This is a second version after entirely scrapping the first.

Even though I've read and revised it a borderline insane number of times…
re-reading the prologue and chapter one still captivates me.

If you make it past that, may you be blessed by the Functional Programming (FP) gods.

Continue to the story.

Acronyms

CS Computer Science 1

FP Functional Programming 1

Site settings

Reading progress
Reading progress