I've been reading the original monad paper called Monads for Functional Programming and as an excercise to understand monads better I decided to re-implement the example code in OCaml. As I am also learning F# I decided to convert it to F# as well
Notable deviation from paper is that I'm using the
(nowadays) more conventional >>=
operator instead
of ⋆
as well as return
instead of unit
(return'
in case of F#).