Solved Problem A of Round 1A CD 2010