Part 2 of HW3