adding haskell code