second part of homework 1