homework 5 and solutions for the haskell programming language 6720357