problem 4 in haskell