first working version of HW2