ch4 exercises
added test