update exercise 4, now working