Mykolka and Andriyko are playing the following game. They write positive integers turn by turn thus forming a sequence a1,a2,...,a2006 obeying the following restrictions: a1=1 (this first turn is fixed, and it is made by Mykolka), and an≤an+1≤3an for 1≤n≤2005. If, after the last turn was made, the sums a1+a2+...+a2004+a2005 and a1+a2+...+a2005+a2006 appear to be mutually prime numbers, then the winner is Andriyko, otherwise it is Mykolka. Who of the players can secure his victory whatever way the other one plays?
This one wants a proof. Work it on paper, then read the official solution and mark yourself. Be honest about it: the record is only any use to you if it is.
Андрійко може забезпечити собі перемогу. Для доведення досить показати, що Андрійко зможе записати число a2006=M−1, де M=∑k=12005ak. Очевидно, що M−1≥a2005. Доведемо, що Андрійко може забезпечити й виконання нерівності a2006=M−1≤3a2005. Нехай Миколка своїм черговим ходом записує число a2k−1, тоді Андрійко відповідає записом числа a2k=3a2k−1, 1≤k≤1002. Оскільки a2k+1≥a2k=3a2k−1, то, додавши нерівності a3≥3a1, a5≥3a3, ..., a2005≥3a2003, будемо мати, що a2005≥1+2A, де A=a1+a3+...+a2003. Таким чином,