Problem 1. How many natural numbers $n$ have the property $P(n)=S(n)=8$, where $P(n)$ and $S(n)$ represent the product and the sum of the digits of the number $n$ (written in base 10)? Justify your answer!
Solution. There are possible numbers of three types.

I. Numbers with one digit 4, one digit 2, and two digits 1. The digit 4 can occupy any of the 4 possible positions, and for each choice of the position of 4, there are 3 choices for the position of 2, the remaining digits being 1. Thus, we obtain 12 numbers of this type

$3 \mathbf{p}$

II. Numbers with three digits 2 and two digits 1. The positions of the two digits 1 can be chosen in 10 ways, the remaining digits being 2. Thus, we obtain 10 numbers of this type. $3 p$

III. The number 8. In total, we obtain 23 numbers $1 p$