edited for hw6_pt1