Recursion added and IO monad wired in.