Current location - Training Enrollment Network - Mathematics courses - Problem Solving: Guess the Numbers on the Head —— A Mathematical Logic Inference Problem
Problem Solving: Guess the Numbers on the Head —— A Mathematical Logic Inference Problem
Disagree with the answer upstairs

If you see someone else's head is 1, you can definitely guess that your head is 2.

For the first time, A must not see 1, otherwise he can guess that his avatar is 2;

For the first time, what B saw was not 1. At the same time, because A just said "I don't know", B can guess that it's not 1 on his head. In this case, B still says he doesn't know, that is to say, what B sees is not 2 (otherwise, if B sees 2 and the head is not 1, he can guess that the head is 3);

In the second round, A knows that it is not 1 and 2 (whether it is 1 or 2 in the first round, B will guess). If he sees that his head is 2, he can guess that he is 3. If he saw that his head was 3, he could guess that his head was 4, but he can't guess now, which means he saw neither 2 nor 3.

In the second round, B knows that his avatar is not 1, 2, 3. If he sees 3, he can guess that his head is 4. If he sees 4, he can guess that his head is 5, so B doesn't see 3 and 4.

In the third round, because B didn't guess correctly in the second round, A knew that his avatar was not 1, 2, 3, 4. At this time, if he sees 4, he will guess that his head is 5. If he sees 5, he will guess that his head is 6, so he doesn't see 4 and 5.

In the third round, B knows that it is not 1, 2, 3, 4, 5 on his head, and he must not see 5, 6, otherwise he can guess this round;

In the fourth round, A knew that his avatar was not 1, 2, 3, 4, 5, 6, and he guessed right this time, which means he must have seen 6 or 7 on B's avatar. If the number on B's head is greater than 7, A can't guess this round. If he sees 6, it means that his head is 7. If he sees 7, his head is 8.

In the fourth round, B can certainly guess the number on his head, because he knows that his number must be smaller than A's 1, because if his number is larger than A's 1, B should guess it first.