Problem 3 completed