Suppose a wicked king is bored and wants to play a game with three of his subjects.
The king first lines the peasants up in single file, and then blindfolds them so they cannot see. The king then informs the peasants that he has 5 hats -- 3 which are red, and 2 which are blue. The king then places one of the hats on each peasant's head in a random fashion and discards the remaining two hats.
The king then informs the peasants that he will remove the blindfolds, and upon doing so, the peasants will be able to see the color of any hat in front of them, but will not be able to see the color of their own hat or any hat behind them.
Then, one of the peasants (could be any one of the three) must state the color of his own hat -- if he is correct, all three peasants' lives will be spared, but if he is wrong, all three peasants will be killed. Other than the one peasant saying "red" or "blue", the peasants are not allowed to talk or communicate or they will all be killed. If none of the peasants answers within a reasonable time after the blindfolds are removed (say, one minute), then the peasants will all be killed.
If the peasants are smart, what is their probability for survival?
Now suppose instead that the king stipulates that only the peasant at the back of the line can answer. What is the probability of survival now?
What is the probability of survival if only the middle peasant is allowed to answer?
What about if only the peasant at the front of the line is allowed to answer?
Originally posted by davegageOk, let's attack the first problem:
Suppose a wicked king is bored and wants to play a game with three of his subjects.
The king first lines the peasants up in single file, and then blindfolds them so they cannot see. The king then informs the peasants that he has 5 hats ...[text shortened]... if only the peasant at the front of the line is allowed to answer?
peasant's agreement: back peasants speaks within 10 secs, mid peas speaks between 10 and 20 secs, front peasant speaks between 20 and 30 secs
If it is your time to speak, and all the hats (if any) in front of you are red, then you say your hat is blue, otherwise you keep quiet.
This strategy will win for the peasants every time.
Originally posted by iamatigerYour strategy won't work: consider that the first peasant sees only red hats in front of him. then by your strategy, he should say "blue", but there are three red hats, so his hat may in fact be red. result: they all die with some probability.
Ok, let's attack the first problem:
peasant's agreement: back peasants speaks within 10 secs, mid peas speaks between 10 and 20 secs, front peasant speaks between 20 and 30 secs
If it is your time to speak, and all the hats (if any) ...[text shortened]... keep quiet.
This strategy will win for the peasants every time.
EDIT: I think you just switched the colors inadvertently, because if we swap red and blue in your answer, then it works nicely...
Originally posted by davegageThanks - I did indeed get confused about which of red and blue was 2 hats.
Your strategy won't work: consider that the first peasant sees only red hats in front of him. then by your strategy, he should say "blue", but there are three red hats, so his hat may in fact be red. result: they all die with some probability.
EDIT: I think you just switched the colors inadvertently, because if we swap red and blue in your answer, then it works nicely...
If the back peasant chooses I get probability of surviving
= (1/10) + (3/10)*(2/3) + (6/10)*(2/3)
= 7/10
If the middle peasant chooses I get probability of surviving
= (2/5)*(3/4) + (3/5)*(1/2)
= 6/10
If the front peasant chooses I get probability of surviving
= 6/10
Optimal strategy:
Back peasant chooses unless he sees RR, in which case another peasant chooses R.
Then optimal probability
= (1/10) + (6/10)*(2/3) + (3/10)
= 8/10
Originally posted by THUDandBLUNDERi agree with the above answers.
If the back peasant chooses I get probability of surviving = 7/10
If the middle peasant chooses I get probability of surviving = 6/10
If the front peasant chooses I get probability of surviving = 6/10
i think it is intersting that the middle peasant has no better chances than the front peasant despite the fact that the middle peasant knows more information (he knows the color of the hat in front of him).
Originally posted by THUDandBLUNDERI think this may be the second best "optimal" strategy; the only uncertainty comes in when the back peasant sees RB or BR, but chooses anyway.
Optimal strategy:
Back peasant chooses unless he sees RR, in which case another peasant chooses R.
Then optimal probability
= (1/10) + (6/10)*(2/3) + (3/10)
= 8/10
But, assuming that the peasants are smart enough to coordinate their efforts as such, then iamatiger's method will work in every case.