Problem 5. From the digits $a, b, c, d, e$, a five-digit number $\overline{a b c d e}$ is formed. For the two-digit numbers $\overline{a b}, \overline{b c}, \overline{c d}, \overline{d e}$, formed from the same digits, it is known that

$$
(\overline{a b}+\overline{b c})(\overline{b c}+\overline{c d})(\overline{c d}+\overline{d e})=157605
$$

Find the number $\overline{a b c d e}$. Multi-digit numbers cannot start with zero.
Answer: 12345 or 21436.

Solution. Note that $157605=3 \cdot 5 \cdot 7 \cdot 19 \cdot 79$. To start, we need to understand which combinations of prime factors correspond to the sums of two-digit numbers. The sum of two-digit numbers cannot exceed $99+99=198$, and $79 \cdot 3$ is already greater than 200, so one of the brackets must be 79. How can the remaining factors be distributed? 79(19.5)(3.7); 79(19.7)(3.5); 79(3.19)(5.7); $79(19)(3 \cdot 5 \cdot 7)$. There are no other cases because in them, a factor greater than 198 is obtained.

Thus, we get the triplets of numbers $(79 ; 95 ; 21),(79 ; 133 ; 15),(79 ; 57 ; 35),(79 ; 19 ; 105)$. Now, note the following: $(\overline{x y}+\overline{y z})=10 x+y+10 y+z=10(x+y)+(y+z)$, and the sums of the digits cannot exceed $9+9=18$. For example, if $(\overline{x y}+\overline{y z})=79$, then this means that $x+y=7$, $y+z=9$. If $(\overline{x y}+\overline{y z})=133$, then either $x+y=13, y+z=3$, or $x+y=12, y+z=13$. If $(\overline{x y}+\overline{y z})=15$, then either $x+y=1, y+z=5$, or $x+y=0, y+z=15$. For instance, we will focus on the set of numbers $(7,9),(12,13),(1,5)$, where the numbers represent possible sums of adjacent digits $\overline{a b c d e}$.

However, if we take the number $\overline{a b c d e}$, it will have only 4 possible pairs of adjacent digits, so the set can have no more than 4 different values. Thus, we rule out the chosen set, as well as all others except one, which will be ( $79 ; 57 ; 35$ ), with the numbers $(7,9),(5,7),(3,5)$. It has only 4 different values: $9,7,5,3$. Moreover, these pairs of numbers need to be arranged so that the values "fit together," that is, like this: $(3,5),(5,7),(7,9)$. Therefore, for $\overline{a b c d e}$, the following will be true: $a+b=3, b+c=5, c+d=7, d+e=9$. This system has only 4 solutions, corresponding to the 5-digit sequences $12345,21436,30527,03254$, the last of which is not suitable because it starts with zero, and the second to last - because for this sequence $\overline{b c}=05$.