4. Let $a>0$ be a real number for which there exist exactly three natural numbers $n$ such that $1<an<2$. How many natural numbers $m$ can there be, for which $2<am<3$?
Solution. The real number $a$ must be less than $\frac{1}{2}$, because otherwise there cannot be more than 2 natural numbers $n$ such that $14$, then $\frac{1}{n-1}5$, will be satisfied:

$$
\frac{1}{n-1}<\frac{2}{n+1} \leq a \leq \frac{1}{n-2}<\frac{2}{n+1}
$$

However, from the inequality $\frac{2}{n+2} \leq \frac{1}{n-2}$ it follows that $2 n-4 \leq n-2$, i.e., $n \leq 6$.

Thus, only the case $n=6$ remains to be considered. In this case, from (2) and (3) we get $a=\frac{1}{4}$, for which there are 3 natural numbers $m$ such that $2<a m<3(m \in\{9,10,11\})$.

Finally, from the previous considerations it follows that there can be

2, 3, or 4 natural numbers $m$ for which $2<a m<3$. Specifically, if $a \in\left[\frac{3}{8}, \frac{2}{5}\right)$ then there are 2 such natural numbers $m$, if $a \in\left\{\frac{1}{4}, \frac{2}{7}\right\} \cup\left[\frac{3}{10}, \frac{1}{3}\right) \cup\left(\frac{1}{3}, \frac{3}{8}\right)$ then there are 3 such natural numbers $m$, and if $a \in\left(\frac{2}{7}, \frac{3}{10}\right)$ there are 4 such natural numbers $m$.