HW6 finished v2