2. Determine all natural numbers $n$, where $1<n<1979$, that satisfy the condition: If $m$ is a natural number, $1<m<n$ and $(m, n)=1$, then $m$ is a prime number.
Solution. Let $S$ be the set of all natural numbers for which the given condition holds. If $n \in S$ and $p^{2}49$ and $n \in S$, then each of the numbers $2,3,5$ and 7 is a divisor of the number $n$. Therefore, $n \geq 2 \cdot 3 \cdot 5 \cdot 7=210>11^{2}$, so $11 \mid n$. Further, it follows that $n \geq 210 \cdot 11=2310>1979$, which is a contradiction. Therefore, $S \subset\{2,3,4, \ldots, 49\}$.

a) Let $n>25$. Then $n \in S$ if and only if $n$ is divisible by $2 \cdot 3 \cdot 5=30$. The only such number is 30.

b) Let $9<n \leq 25$. Then $n \in S$ if and only if the number $n$ is divisible by $2 \cdot 3=6$. This holds for the numbers 12, 18, and 24.

c) Let $4<n \leq 9$. Then $n \in S$ if and only if the number $n$ is even. These are the numbers 6 and 8.

d) It is easily verified that each of the numbers 2, 3, and 4 belongs to the set $S$.

According to this, $S=\{2,3,4,6,8,12,18,24,30\}$.