USA Math Olympiad Question