Problem

Source: Iberoamerican MO 2024 Day 2 P5

Tags: combinatorics, number theory



Let $n \ge 2$ be an integer and let $a_1, a_2, \cdots a_n$ be fixed positive integers (not necessarily all distinct) in such a way that $\gcd(a_1, a_2 \cdots a_n)=1$. In a board the numbers $a_1, a_2 \cdots a_n$ are all written along with a positive integer $x$. A move consists of choosing two numbers $a>b$ from the $n+1$ numbers in the board and replace them with $a-b,2b$. Find all possible values of $x$, with respect of the values of $a_1, a_2 \cdots a_n$, for which it is possible to achieve a finite sequence of moves (possibly none) such that eventually all numbers written in the board are equal.