Got types working for Ex2_04.scala
Fix type errors in Ex2_04.hs, based on Ex2_04.scala