euler 29 solution haskell