Prisoners And Hats Puzzle

The prisoners and hats puzzle is a logic puzzle that involves reasoning about the actions of other people, drawing in aspects of Game theory. There are many variations, but the central theme remains the same.

The puzzle

According to the story, four prisoners are arrested for a crime, but the jail is full and the jailer has nowhere to put them. He eventually comes up with the solution of giving them a puzzle so if they succeed they can go free but if they fail they are executed. The jailer puts three of the men sitting in a line. The fourth man is put behind a screen (or in a separate room). He gives all four men party hats (as in diagram). The jailer explains that there are two red and two blue hats. The prisoners can see the hats in front of them but not on themselves or behind. The fourth man behind the screen can't see or be seen by any other prisoner. No communication between the men is allowed. If any prisoner can figure out and say (out loud) to the jailer what colour hat they have on their head all four prisoners go free. The puzzle is to find how the prisoners can escape.

The solution

For the sake of explanation let's label the prisoners in line order A B and C. Thus B can see A (and his hat colour) and C can see A and B. The prisoners know that there are only two hats of each colour. So if C observes that A and B have hats of the same colour, C would deduce that his own hat is the opposite colour. However, if A and B have hats of different colours, then C can say nothing. The key is that prisoner B, after allowing an appropriate interval, and knowing what C would do, can deduce that if C says nothing the hats on A and B must be different. Being able to see A's hat he can deduce his own hat colour. (The fourth prisoner is irrelevant to the puzzle: his only purpose is to wear the fourth hat). In common with many puzzles of this type, the solution relies on the assumption that all participants are totally rational and are intelligent enough to make the appropriate deductions.

 

<< PreviousWord BrowserNext >>
boys town
vowel roundedness
dan margalit
citytv barcelona
second fleet
united hockey league
list of vowels
james van der beek
dumisani kumalo
hms marlborough
after school special
duality (order theory)
lunchbox (marilyn manson album)
lieutenant scheisskopf
animals in space
sancy
ray mallon
ripley, michigan
pink lady and jeff
anne de pisseleu d'heilly
nocti
puyo puyon
if you tolerate this your children will be next
molecular disrupter device
municipalities of pirkanmaa
west mercia constabulary
list of zip codes in michigan
religion in argentina
municipalities of south karelia
you stole the sun from my heart
saint cecilia
erlang shen
australian aboriginal sovereignty
list of polish wars
municipalities of finland proper
psyvariar 2
sergei zubov
the city and the stars
tsunami (1999 single)
zirl
iquitos
louise de la vallire
bonnie nardi
american tower management