added results for exercise 10 from https://github.com/pchiusano/fpinscala/blob/master/answers/src/main/scala/fpinscala/state/State.scala