finished up work for chapter 3