completes chapter 7 exercises