partition in haskell