34. a) Find the smallest integer starting with the digit 1 such that if this digit is moved to the end, the number triples. Find all such numbers.

b) What digits can non-zero integers start with if they triple when the first digit is moved to the end? Find all such numbers.
34. a) First solution. Let's denote the (m-digit) number obtained by removing the first digit 1 from the desired number as \(X\). In this case, according to the problem, we have:

\[
\left(1 \cdot 10^{m} + X\right) \cdot 3 = 10 X + 1
\]

from which

\[
X = \frac{3 \cdot 10^{m} - 1}{7}
\]

From the last equation, it is not difficult to determine the number \(X\). For this, we need to divide the number \(3 \cdot 10^{m} = 30000\) ... by 7 until the remainder is 1. As a result, we have:

![](https://cdn.mathpix.com/cropped/2024_05_21_b937612abb2773f7abffg-100.jpg?height=376&width=263&top_left_y=184&top_left_x=433)

Thus, the smallest possible value of the number \(X\) is 42857, and the smallest value of the desired number is 142857.

In the division process, we could have continued beyond the first 1 and continued dividing until the next 1, and so on; in this case, we would have obtained numbers

![](https://cdn.mathpix.com/cropped/2024_05_21_b937612abb2773f7abffg-100.jpg?height=98&width=395&top_left_y=752&top_left_x=361)

that also satisfy the condition of the problem.

Second solution. Let's denote the second digit of the desired number by \(x\), the third by \(y\), and so on, i.e., assume that the desired number has the form \(1 x y \ldots z t\) (the bar above indicates that here we have not the product \(1 \cdot x \cdot y \ldots z \cdot t\), but a number composed of the digits \(1, x, y, \ldots, z, t\)). In this case, according to the problem, we have:

\[
\overline{1 x y \ldots z t} \cdot 3 = x \overline{x y \ldots z t 1}
\]

From this, it follows that \(t = 7\) (in no other case would the product on the left end in 1). Therefore, the tens digit of the number on the right is 7. This is only possible if the product \(z \cdot 3\) ends in \(7 - 2 = 5\) (two tens on the right are obtained from the product of the last digit of the desired number 7 by 3), i.e., \(z = 5\). Now we know the hundreds digit of the number on the right: 5; therefore, the hundreds digit of the desired number must give a number ending in \(5 - 1 = 4\) (1 is the tens digit of the product 5.3). The calculations will end when we reach the first digit 1. It is convenient to arrange them as follows:

\[
\begin{array}{ccccc}
1 & 4 & 2 & 8 & 57 \\
4-1=3, & 2-\dot{0}=2, & 8-\dot{2}=6, & 5-1=4, & 7-\dot{2}=\dot{5}
\end{array} \times 3 = \cdots \cdots 142857
\]

(calculations are performed from right to left). Thus, the smallest number satisfying the conditions of the problem is 142857.

If we do not stop at the first obtained 1 in our calculations and continue further, we will obtain other numbers,

![](https://cdn.mathpix.com/cropped/2024_05_21_b937612abb2773f7abffg-101.jpg?height=94&width=395&top_left_y=179&top_left_x=494)

b) Since the number of digits does not increase when such a number is tripled, the first digit of the number can only be 1, 2, or 3.

As we saw in the solution to part a), it can be 1. Let's now show that it cannot be 3.

Indeed, if the first digit of the desired number is 3, then the second digit, equal to the first digit of the tripled given number, is 9. But the result of multiplying a number starting with the digits 39 by 3 has more digits than the original number; therefore, it cannot be obtained from the original number by moving the first digit to the end.

We leave it to the readers to prove independently that the desired numbers can start with the digit 2. The smallest such number is 285714; all such numbers starting with the digit 2 have the form

![](https://cdn.mathpix.com/cropped/2024_05_21_b937612abb2773f7abffg-101.jpg?height=94&width=394&top_left_y=716&top_left_x=481)

(the proof is analogous to the solution of part a)).