The king was looking to hire a new scribe. Three bright young lads applied for the job. The king, who was widely known for being very just, made them undergo a test. He took three red and three black hats, and told them that the one who will guess the color of his own hat, will win the honorable title of being the king's scribe. The applicants were blindfolded, a red hat put on the head of each of them, and the three black hats were hidden away.

After the blindfolds were removed, the three applicants stood there for a while in silence, thinking. Each of them could see the hats of the other two, but none of them could see their own hat.

After some time, one of them said that he has a red hat on his head, correctly guessing the solution to the test.

What was the logic behind it?

  • $\begingroup$ I believe the riddle is wrong. It can't be argued correctly and "honesty" is not the key. The riddle goes like this. There are only 2 black hats, and 3 red hats. The rest is the same. -- Now, the one who is smartest can figure out fastest that he wears a red hat. How? -- Suppose he wears a black hat, then the others would see a black and red hat and wondered what hat they had. They would reason that if they had a black hat, the other one would know it immediately, seeing two black hats. Since nothing happens, none of the other two sees a black hat, so he wears a red hat! $\endgroup$
    – Cuc
    Apr 12, 2016 at 6:21
  • $\begingroup$ @Cuc : I know the riddle you mentioned, and it is a completely different riddle. Actually, the riddle you mentioned is the basic version of the hat guessing riddle. I thought it was common knowledge, that's why I didn't post it. $\endgroup$
    – vsz
    Apr 12, 2016 at 6:24
  • $\begingroup$ Alright, I guess you have me puzzled. I thought we are missing information, and I noticed the difference. I realize now how the fairness comes in from the King being "just". My bad. $\endgroup$
    – Cuc
    Apr 13, 2016 at 2:51
  • $\begingroup$ Why did the "@vsz" (at vsz) disappear in my previous comment? O, I get it, perhaps because the riddle is from vsz . . . Shoots, I am still a newby, I guess. $\endgroup$
    – Cuc
    Apr 13, 2016 at 2:52
  • $\begingroup$ Having enough hats of each color available, if the king would throw a perfect coin head/tail to choose red/black hat for each applicant, that would be perfectly fair and every applicant would have equal probability 1/2 to guess own color, regardless of other applicants colors. This holds for any n, not just n=3. And already when still blindfolded. In any fair guessing test the king will not hire the brightest but the luckiest applicant. The king might have added: only guess if you are 100% sure. Then a bright applicant might realize all colors are the same. Otherwise no applicant would guess. $\endgroup$ Oct 19, 2021 at 12:47

3 Answers 3


The king has to be nondiscriminatory for each person applied to this job so putting one black on one of them and two red on the others would make the game unfair! So The only way to make this game fair is to put the same color on all of them.

The king, who was widely known for being very just

so one of the player might have suspected this possibility and said red!

  • $\begingroup$ To complete the answer: the unfairness would come from the fact that if you see 1 red and 1 black hat, you have a 50% of guessing correctly, but with seeing two of the same color, the chance of a random guess would be 75%. Thus, the only fair setup is when all the colors are the same. $\endgroup$
    – vsz
    Apr 10, 2016 at 17:10
  • 4
    $\begingroup$ I fail to see how seeing two hats of the same color improve the chance of a random guess. You don’t know how the hats are picked, you have no reason to suppose the hat you wear was chosen randomly among the remaining hats. It even so occurs that it was not! $\endgroup$
    – Édouard
    Apr 10, 2016 at 17:34
  • 3
    $\begingroup$ @Édouard I agree with you. If I see two black hats, I could have a black or a red. If I see one of each, I could have a black or a red. If I see two red hats, I could have a black or a red. In all cases, no one else would know any more information than I, so all cases are fair. $\endgroup$
    – Trenin
    Apr 12, 2016 at 16:52
  • 1
    $\begingroup$ @vsz : can you provide mathematical details on how you calculated the 50% and 75% $\endgroup$ Oct 19, 2021 at 12:12

The applicant who correctly "guessed" his hat color took it off and looked at it. The rules didn't prohibit doing that, after all. The other two applicants, who had doubtless spent too much time reading logic puzzles, weren't clever enough to notice that they weren't in a conventional "hat puzzle".

  • $\begingroup$ They are supposed to guess the colour of their hat. If I look at my hat, I know its colour and I cannot guess it anymore... $\endgroup$
    – Evargalo
    Oct 18, 2021 at 12:45
  • $\begingroup$ @Evargalo In these puzzles, it's common to phrase it as a "guess" even though the subject has determined the color of their hat as a logical certainty. But in any case, there's some miniscule chance that they were wrong about what they were seeing, so in that sense there's still an element of guessing. $\endgroup$
    – Sneftel
    Oct 18, 2021 at 12:52

There are three possibilities regarding my two competitors:

  • they both have black hats
  • one has a black, one red
  • they both have red hats

If the king liked scribes who take risks, then my hat is different from the others or the middle option be true, in which case I would not want the job as I am not a risk-taker but pride myself on logic.

As kings do not normally like risk-takers the answer must be the same colour as my competitors.

Thereupon, the others copied me and he went with his nephew by marriage as expected.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.