added types
some simple IO and monads