1. On an island, there are two tribes: the tribe of knights, who always tell the truth, and the tribe of liars, who always lie. On the main holiday, 2017 islanders sat around a large round table. Each islander said the phrase: "my neighbors are from the same tribe." It turned out that two liars made a mistake and accidentally told the truth. How many liars can sit at this table?
Answer: 1344 liars

Solution. Note that no two knights can sit next to each other, meaning the neighbors of each knight are liars. Indeed, consider a chain of knights sitting in a row, surrounded by liars. Suppose there are at least two knights in this chain. The neighbors of the extreme knight are a knight and a liar, but this is impossible since the knight would then be lying. Therefore, no two knights sit next to each other, and the neighbors of each knight are liars.

We will call those liars who did not make a mistake, true liars. According to the condition, the neighbors of each true liar are from different tribes. Therefore, the neighbors of true liars must be a knight and a liar. This means the sequence "LRLRL...LRL" repeats until it encounters a false liar. If a knight sits before him, then a knight also sits after him. If a liar sits before him, then a liar also sits after him. Therefore, the seating arrangement with false liars can be obtained from the seating arrangement "LRLRL...LRL" by either seating a false liar between two liars or by a true liar leaving the table (and then his neighbor liar becomes a false liar). The first action increases the remainder of the total number of people sitting at the table divided by 1, the second decreases it by 1. Since in the seating arrangement "LRLRL...LRL" the number of islanders is divisible by 3, and 2017 gives a remainder of 1 when divided by 3, we need to reduce the remainder 0 by 1 twice. Thus, we need to remove two liars from the seating arrangement of 2019 islanders. Therefore, the number of liars is $2019 \cdot \frac{2}{3}-2=1344$.