updated tests for HW0_p2 Binary of 4 and refactored and repaired p2