some haskell solutions