merge test/scala and main/scala
 examples in chapter10.2-6