What color is my hat?

Logic Level 2

A police officer has caught four criminals and plays a game with them. They are not allowed to communicate with each other during the game but are allowed to discuss strategy before.

He lines up three of the prisoners (A, B, C) in one room, placing the fourth prisoner (D) in a separate room where he can hear the other three shout out. Each prisoner is given a hat to wear, blind-folded. The officer tells them that there are in total two blue hats and two red hats.

  • prisoner A can see the colors of the hats worn by prisoners B and C;
  • prisoner B can only see the color of the hat worn by prisoner C.

The game proceeds as follows:

  • In the first minute, Prisoner A's blindfold is opened. A can either guess the correct answer or say, I do not know the color of my hat .
  • In the second minute, Prisoner B's blindfold is opened and it's B's turn to guess.
  • In the third minute, Prisoner C's blindfold is opened and it's C's turn to guess.
  • In the fourth minute, Prisoner D's blindfold is opened and it's D's turn to guess.

The prisoners being perfect logicians, it is guaranteed that one of them can always guess his color accurately. Which one?

A B C D

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

3 solutions

If A sees 2 hats of the same colours he would know his colour, but he sees 2 different colours. B should conclude that if A stays silent he sees 2 colours. So he knows he has a different colour from C. Hence he will call his colour.

Technically, A could just be slow to show that he knows his color.

Any suggestions for how to improve the phrasing of the problem?

Calvin Lin Staff - 4 years, 6 months ago

Log in to reply

I made an assumption that A doesn't know his color based on the phrase "After a few moments of silence". If we want to make it more obvious, we can say "Given that A doesn't know the answer and thus missed his opportunity to answer, someone shouted the correct color. Who could it be?".

Christopher Boo - 4 years, 6 months ago

For absolute completeness I think you need to demonstrate neither C nor D can have the correct answer (even though the problem indicates it will be only 1 who knows).

Jason Dyer Staff - 4 years, 5 months ago

Log in to reply

If A tell his hat color, than B C and D can also guess their hat color.

If A cannot guess his hat color, than B can guess his color.Knowing the hat color of B, Ccan also tell his hat color.

Hence B and C will always give the correct answers

Arpit Moga - 2 years, 1 month ago
Cheah Chung Yin
Mar 12, 2017

From my reasoning, I think both B and C can always guess their color accurately.

In the case if A sees 2 hats of the same color, he will be able to guess his hat color, making B realize that he has the same hat color as C and guess his color. C will reason that since A knows his own hat color, he must have the same hat color as B. Since he hears B's color guess, he can also deduce his hat color. Here, D will also know his own color because B and C has the hats of a same color.

In the scenario that A sees 2 hats of different colors, he will say that he does not know his color. B realizes that he has a different color from C and will make the guess. C then reasons that since A does not know his own color, he must have a different color from B. He only has to guess the color different from what A just said. Here, D does not know his own color.

Saya Suka
Apr 4, 2021

Two of them actually.

Saw / Heard (1) Guessed (1) Saw / Heard (2) Guessed (2)
A 1 colour the other colour not seen 2 colours "I don't know"
B C's colour + A's answer same colour seen / different colour heard C's colour different colour seen
C A's & B's answers matching B's B's answer different from B's
D 3 other answers the colour mentioned first / once 2 different colours "I don't know"

The second colour answers must be opposite to the first ones. Only A and B need to have their blindfolds lifted.

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...