Added comments; changed format in order for the Haskell code to be applicable to lhs2TeX