P124.4.2.2019.3.2 stones are placed into two non-empty boxes. Each second Alex chooses a box with an even amount of stones and shifts half of these stones into another box.
Prove that for each ,, at some moment there will be a box with exactly stones.
Solution
Note that is prime and is prime as well.
Let be variables which correspond to the number of stones in the two boxes. Observe that at all times. Now, notice that every move halves each of modulo In other words, if are turned into after Alex does his shifting, then we have With this observation, it would suffice to prove that is either a primitive root modulo or is the square of the primitive. This is equivalent to , and so we just need to show that However, this is obvious since