4A. Find the largest natural number that is less than the sum of the squares of its digits.
Solution. Let $\overline{a_{n} \ldots a_{1} a_{0}}$ be the desired number, that is,

$$
a_{n} \cdot 10^{n}+\ldots+a_{1} \cdot 10+a_{0}10^{k}-9>90$, which means that the sum on the left side is positive. According to this, the number must be less than 100. Since $99<9^{2}+9^{2}$, the number 99 is the desired number.

4B The area of the base of a right triangular prism is equal to $4 \mathrm{~cm}^{2}$, and the areas of the lateral surfaces are equal to 9, 10, and $17 \mathrm{~cm}^{2}$. Determine the volume of the prism.