Skip to main content
OlympiadHQ

Browse · MathNet

Print

48th Austrian Mathematical Olympiad Regional Competition (Qualifying Round)

Austria counting and probability

Problem

The nonnegative integers , and are written on a blackboard. Alice and Bob play the following game: Alice begins, then they play in turns. A move consists in replacing one of the three numbers by the absolute difference of the other two. No moves are allowed where all three numbers remain unchanged. A player in turn who cannot make a legal move loses the game. Prove that the game will end for every number . Who wins the game in the case ?
Solution
If three numbers are written on the blackboard and one of them is replaced by the (positive) difference of the other two, then after this move one number on the blackboard will be the sum of the other two. Let , and be the numbers on the blackboard; w.l.o.g. we assume that . Because of and there is only one possible move. After it the numbers , and are written on the blackboard. Again, one number (namely ) is the sum of the other two and there exists only one possible move. This means that at the latest from the second turn on there is no choice of moves and all moves are inevitable. Furthermore, from the second move on, the largest of the three numbers is decreased, and since no number can become negative, after a finite number of moves one of the numbers will be . Since is the difference of the other two numbers, we must have , , on the blackboard. Now and , therefore no further move is possible. Thus the player writing , , onto the blackboard is the winner. If the game starts with the numbers , and on the blackboard, the course of the game is as follows: 1st move (A): , , 2nd move (B): , , 3rd move (A): , , etc. (since ...) 117th move (A): , , 118th move (B): , , 119th move (A): , , 120th move (B): , , 121st move (A): , , 122nd move (B): , , 123rd move (A): , , 124th move (B): , , 125th move (A): , , and A wins the game.
Final answer
Alice

Techniques

Invariants / monovariantsGames / greedy algorithms