finished chapter 10, almost fully functional