Part 2 of homework