# Task 2. (2 points)

Knights and liars played "Chinese whispers" according to the following rules: the first in the chain whispers a number to the second, the second to the third, and so on. The last person in the chain announces the number aloud. At the same time, a knight repeats the same number that was told to them, while a liar adds or subtracts one.

The first person (a knight) told their neighbor the number 10. The last person announced the number 13.

After that, the participants played this game again, but this time they passed the numbers to each other in reverse order. The last person told their neighbor the number 12, and the first person announced the number 9 at the end of the game.

Who was the last person in the chain?
Answer: Knight

Solution:

In the first game, the number does not change parity, which means the number of liars in the chain from the second to the last is odd.

From the result of the second game, we get that the number of liars in the chain from the second-to-last to the first is also odd.

This means that the first and last people are of the same type, so the last one is also a knight.