## Task B-1.4.

In each of the five baskets, there is a certain number of balls. From the first basket, we transfer one fifth of the balls to the second basket. Then from the second basket, we transfer one fifth of the balls to the third basket. After that, from the third basket, we transfer one fifth of the balls to the fourth basket. Then we transfer one fifth of the balls from the fourth basket to the fifth basket. Finally, from the fifth basket, we transfer one fifth of the balls to the first basket. Now, each basket has exactly 32 balls! How many balls were there in each individual basket at the beginning?
## First solution.

After the last transfer of one-fifth of the balls from the fifth basket to the first basket, 32 balls remained in the fifth basket. If $x$ is the number of balls in the fifth basket before transferring one-fifth of the balls to the first basket, then

$$
\frac{4}{5} \cdot x = 32
$$

Thus, $x = \frac{5}{4} \cdot 32 = 40$ balls.

Therefore, $\frac{1}{5} x = \frac{40}{5} = 8$ balls were transferred to the first basket. After transferring one-fifth of the balls to the second basket, there were $32 - 8 = 24$ balls in the first basket,

which means that initially, there were $\frac{5}{4} \cdot 24 = 30$ balls in the first basket.

Next, we transfer one-fifth, i.e., $\frac{30}{5} = 6$ balls from the first basket to the second basket, which initially had $b$ balls. We have

$$
\frac{4}{5} \cdot (b + 6) = 32
$$

Thus, the initial number of balls in the second basket is 34.

Therefore, after transferring one-fifth from the first basket, there were $34 + 6 = 40$ balls in the second basket. One-fifth of this number, i.e., 8 balls, were transferred to the third basket, which contained $c$ balls, and we have

$$
\frac{4}{5} \cdot (c + 8) = 32
$$

The initial number of balls in the third basket is 32.

Similarly, we conclude that there were initially

$$
40 - \frac{40}{5} = 32
$$

balls in the fourth and fifth baskets. Therefore, the baskets initially contained 30, 34, 32, 32, 32 balls, respectively.