Find all six-digit numbers that increase by an integer factor when the last digit is moved to the beginning.

#
Let's write the condition as $n(10 a + b) = 10^5 b + a$, where $a$ is a five-digit number, $b$ is the last digit of a six-digit number, and $n$ is an integer from 1 to 9. Rewriting this equation as $\left(10^5 - n\right) b = (10 n - 1) a$, we see that $\left(10^5 - n\right) b$ is divisible by $10 n - 1$.

The case $n=1$ is obvious.

For $n=2,3,6,8,9$, the number $10 n - 1$ is a prime two-digit number (19, 29, 59, 79, 89, respectively), so the digit $b$ does not divide it. It is not difficult to check that in each of these cases, $10^5 - n$ is also not divisible by $10 n - 1$.

For $n=7$, the number $10 n - 1$ is 69. $b$ can be divisible by 3. But 99994 is not divisible by 23.

For $n=4$, the number $10 n - 1$ is 39. $99996 = 39 \cdot 2564$. Checking confirms that all five-digit numbers $2564 \cdot 4, 2564 \cdot 5, \ldots, 2564 \cdot 9$ work.

For $n=5$, the number $10 n - 1$ is 49. $99995 = 7 \cdot 14285$. 14285 is not divisible by 7, so $b=7$. Indeed, the number 142857 works.

## Answer

142857, 102564, 128205, 153846, 179487, 205128, 230769, 111111, 222222, ..., 999999.

Send a comment