finished chapter 4 (non-exercises)