Added monad generic interface and make pair_expected a model of monad

The genric monad code should be moved to a monads.hpp file. I thinks
that this merits its own library.
Ignore all .o files