snippets of code I wrote while learning haskell