finished problem number 3