Practical implementation of a couple of popular monads.