HW4 Exercise 3