Move the last two digits in front to multiply by $6$

Here is the problem:

Can you determine the smallest natural number $N>0$ not divisible by $10$, such that when you move the last two digits of $N$ to the front, shifting the other digits two places to the right, you end up with $6N$?

For example $N=1234567$ will not work, since $6N=7407402$ whereas moving the last two digits in front results in $6712345$. It is not allowed to fill in zeros in case that helps, so $67012345$ is not an option in the current example. Also note, that the last two digits must remain in the same order as they originally were. Also you can only use base 10 numbers.

The current question was inspired by this other question found on this site.

Solutions Collecting From Web of "Move the last two digits in front to multiply by $6$"

If we take $N=100b+a$ with $10^{n-1} < b < 10^n$, then the specified condition is:

$$\begin{align}\\
a10^n+b &=6(100b+a) \\
(10^n-6)a &=599b\\
\end{align}$$

So $599$ is prime and therefore we need $599 \mid (10^n-6)$, that is, $10^n \equiv 6 \bmod 599$. This happens first for $n=297$. To bring $a$ into range, and avoid multiples of $10$, we need to multiple by $61$. In principle, then, we will need $N = \dfrac{6100(10^{297}-6)}{599}+61$

Check the digits out here


I solved the reverse problem first, by mistake. In this version, I shift the first two digits of $N$ to the end, and that gives six times $N$.

$$\begin{align}\\
6(a10^n+b) &=100b+a \\
(6\cdot 10^n-1)a &=94b\\
\end{align}$$

We cannot have $b=(6\cdot 10^n-1)$ so we must have $94 \mid (6\cdot 10^n-1) \implies 47 \mid (6\cdot 10^n-1)$

So the smallest value for which this is feasible is $n=44$, where:
$(6\cdot 10^n-1)/47 = 12765957446808510638297872340425531914893617$

In order for $a$ to have two digits, we need $b$ to be $5$ times this number (giving $a=10$), and

$$N=1063829787234042553191489361702127659574468085$$

First thing to note: your $N$ and $6N$ have the same number of digits.

Since we’re working in base 10, this means we know that our number is less than or equal to $16…6$ and greater than $10…0$, since if we multiple $9…9$ (one less digit than the numbers before) by $6$, we’ll get one digit more than $9…9$ has.

That’s a fairly small window, and also, it gives us the first digit of $N$ as $1$. This narrows down our search for the first digit of $6N$ also: it can be no less than $6$. Thus, the 5th digit of $N$ can be no less than $6$.

Now, let’s say $N = 100b + a$ for $60 < a < 100$ and $1000 < b < 1666$.

Then we also know $6N = 10000a + b$. Then we have that $9999a – 99b$ is divisble by 5, so $101a – b$ is divisible by $5$, thus $a – b$ is divisible by $5$. This tells us that the 6th digit of $N$ is either exactly the 4th digit of $N$ or their difference is $5$.

Let $N$ have $m+1$ digits. We have $N= 100x+10a+b$, where $x$ has $m-1$ digits. Moving the last two digits in front we obtain,
$$6N = 10^ma + 10^{m-1}b + x \implies 600x + 60a + 6b = 10^ma + 10^{m-1}b + x$$
Hence, we need
$$599x = (10^m-60)a + (10^{m-1}-6)b = (10^{m-1}-6)(10a+b)$$
This means $599$ divides $(10^{m-1}-6)(10a+b)$. Further, $10a+b$ is a two digit number and $599$ is a prime. Hence, we need $m$ such that $599$ divides $10^{m-1}-6$. This gives us $m=298,597,\ldots$. I trust you can finish it off from here.