homework1 final version