fix Lab_4_Part_2 bugs