Part of 1989 National High School Mathematics League
Source: 1989 National High School Mathematics League, Exam One, Problem 15