In the buffet of the kitchen, there are three candy boxes, each containing the same number of candies. Every time when Juku goes into the kitchen, he takes either three candies from one box or one candy from every box. Prove that irrespectively of how Juku takes the candies, he always retains the possibility to completely clean out all candy boxes. (Juniors.)
, 2010
Solution
The difference of the numbers of candies in any two boxes can only be a multiple of because it is in the beginning and, with every move, it changes by either or . Hence, starting from an arbitrary intermediate state, Juku can clean out the boxes as follows: he takes one candy from each box as many times as possible, after which one box is empty and the number of candies in each of the other two is divisible by , and then empties the other boxes by taking three candies from one box every time.
Want a route through all this instead of an archive? The track
puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.