Algorithm Design with Haskell