final version of homework1