chapter 6: exercises 3 and 4