completed exercises end of chap 5