Examples of Functor, Applicative, Monoid and Monad implemented in Ruby