- finished problem 3