$12 \cdot 2$ There are two small piles of small stones. If 100 stones are taken from the first pile and put into the second pile, then the second pile will have twice as many stones as the first pile. Conversely, if some stones are taken from the second pile and put into the first pile, then the first pile will have five times as many stones as the second pile. What is the minimum number of stones that could be in the first pile? And in this case, how many stones are in the second pile?
(14th All-Russian Mathematical Olympiad, 1988)
[Solution] Let the first pile have $x$ stones, the second pile have $y$ stones, and the second pile adds $\approx$ stones to the first pile. According to the problem,
$$
\left\{\begin{array}{l}
2(x-100)=y+100, \\
x+z=6(y-z) .
\end{array}\right.
$$

From (1) we get
$$
\begin{array}{c}
y=2 x-300, \\
11 x-7 z=1800, \\
4 x+7(x-z)=1800 .
\end{array}
$$

Substituting into (2) we get
Since 4 divides $4 x$, and 4 divides 1800, then
$$
4 \mid 7(x-z) \text{. }
$$

Since $(4,7)=1$, then
$$
4 \mid x-z \text{. }
$$

Let $x-z=4 t, t \in \mathbb{N}$, then
$$
\begin{array}{l}
4 x+28 t=1800, \\
x+7 t=450 .
\end{array}
$$

Thus
$$
\left\{\begin{array}{l}
x=-7 t+450, \\
y=2 x-300=-14 t+600, \\
z=x-4 t=-11 t+450 .
\end{array}\right.
$$

Since $x, y, z \in \mathbb{N}$, then
$$
\left\{\begin{array}{l}
-7 t+450>0, \\
-14 t+600>0, \\
-11 t+450>0
\end{array}\right. \text{. }
$$

Considering $t$ is an integer, then
$$
t \leqslant 40 .
$$

When $t$ takes the maximum allowable value 40, from $x=-7 t+450$ we get $x$ takes the minimum value 170, at this time $y=40, \quad z=10$.
Upon verification
$$
\left\{\begin{array}{l}
x=170 \\
y=40 \\
z=10
\end{array}\right.
$$

is the solution we seek.