finished problem 2 of homework3