Refine solution to phone number problem.