add haskell solution to problem 5