solved problem set 1 part 3