Looks like there's a space leak in computing expectations?
setStdGen for deterministic randomness.
Applicative and Monad are superclasses of Monad'.