Adding in chapter 7 higher order function exercises; To be completed