Haskell solutions to early problems