# 100 black hats and 99 white hats (Is my solution wrong?)

100 people are sitting in a circle, where every person can see the 99 other people. All of them are wearing hats but they can only see the hats of other people, meaning they can't see their own hat. There are 99 white hats and 100 black hats. People start saying what they know about the color of their own hats. The game ends when a person says the color of their hat with clear knowledge of it.

• The 1st person says: "I don't know the color of my hat."
• The 2nd person says: "I don't know the color of my hat."
• The 3rd person says: "I don't know the color of my hat."
• ...

Everyone gives the same answer until it is your turn. You are the 100th person. All you see is black hats. What is the color of your hat?

(I have developed an answer to this question, but it doesn't feel right. I would like you to explain where exactly I have made a mistake in my answer - if I have. I would also encourage you to try the question on your own first.)

• This seems closely related to the "blue eyes riddle". puzzling.stackexchange.com/questions/100217/… Aug 2, 2020 at 23:24
• Thank you. This has been driving me crazy for some time but now I have assurance that this type of logic is actually valid. Aug 2, 2020 at 23:49
• This puzzle depends on shared knowledge, and doesn't have a solution without it. Every person must know that their hats were selected from this particular pool of 199 hats without replenishing in between, and every person must know everyone else also knows this. This is why the puzzle is usually posed as "one day, the oracle announced to the villagers (all blue-eyed) that at least one of them has blue eyes". (Also, maybe change the wording a bit so that it doesn't sound like the 100 people have 199 heads?)
– Bass
Aug 3, 2020 at 4:59
• As long as they're all perfect logicians then it should use the same blue eyes riddle logic. Aug 3, 2020 at 5:02

## 1 Answer

You think:

If the color of my hat was white, the 99th person would think:

• If the color of my hat was white, the 98th person would think:
• If the color of my hat was white, the 97th person would think:
• ...
• If the color of my hat was white, the 1st person would think:
• There are 99 white hats in total. I see 99 white hats. So my hat must be black.

If my hat was white, the 99th person would be able to reason out the color of his hat in this fashion. He didn't. Meaning my hat is black.

READ THIS ONLY IF YOU DON'T UNDERSTAND WHAT I AM TRYING TO SAY:

• If everyone except the 1st person was wearing a white hat, the 1st person would guess that their hat was black.

• If everyone except the 1st and 2nd person was wearing a white hat, the 2nd person would think that if his hat was white, the previous situation would apply. But it didn't, so the 2nd person would guess that their hat was black.

• If everyone except the first 3 people was wearing a white hat, the 3rd person would think that if his hat was white, the previous situation would apply. But it didn't, so the 3rd person would guess that their hat was black.

• ...

You basically extend this list until you are left with no one wearing a white hat and that is the solution. It feels wrong because you are somehow exploiting the 99 white hat limit when there are 0 people wearing a white hat. I would either like an explanation to where exactly I made a mistake, or an assurance on how this answer is correct.

• I will note though that when you say "If everyone except the 1st and 2nd person was wearing a white hat, the 2nd person would think that if his hat was white... so the 2nd person would guess that their hat was black." Isn't sound reasoning. The second person knows their hat is black because they know the first situation didn't apply AND they can see 98 other people have white hats. It boils down to: they have a black hat but don't know their hat color because they see someone who has a black hat that isn't any black hatted person before them. Aug 3, 2020 at 6:36
• Another way of looking at it: each person who says "I don't know" is, in effect saying "at least one person going after me has a black hat." For any person, if that wasn't true, they would know they have a black hat. Since the 99th person said that and you're the only one after them, you now know you have a black hat. Aug 3, 2020 at 17:28