adding exercises from Functional Programming in Scala