2. In a company of 39 people, each is either a knight (always tells the truth) or a liar (always lies). They took turns making the following statements:

- "The number of knights in our company is a divisor of 1";
- "The number of knights in our company is a divisor of 2";
- "The number of knights in our company is a divisor of 3";
- $\ldots$
- "The number of knights in our company is a divisor of 39".

How many knights could there be in this company?
Answer: 0 or 6.

Solution. Let $k$ be the number of knights in the company. If $k=0$ (everyone is a liar), then everyone lied, as they should. If $k>0$, the correct answers will be the answers with numbers $k, 2k, 3k, \ldots, mk$, where $mk \leqslant 39$. The total number of correct answers will be $m$. If $k=1,2,3,4,5$, there will be too many correct answers: $m=$ $39,19,13,9,7$ respectively; this leads to a contradiction: $m>k$. If $k=6$, there will be exactly 6 correct answers, as it should be. If $k \geqslant 7$, there will be no more than five numbers that are multiples of $k$, which is less than $k$, leading to a contradiction.

Grading. 12 points for a correct solution. If the case $k=0$ is missed, 8 points. If only the case $k=0$ is considered, 3 points. If only that $k=6$ fits is shown, 4 points.