Exercises from chapter 7