Part 2 of homework 6.