fixed for HW2