Completed exercises 3.5 1-3