Part one of homework 4 done