End of chapter 3 exercises