almost completed hw5 q1