Every wizard sees x red hats and 99-x blue, one of these is even and one odd. In reality the number of red hats could be either even or odd. We work with the assumption that the number of red hats should be even. Every wizard chooses his or her hat colour so that the total number of red hats is even. Thus we have a 50% chance of saving everyone and 50% chance of having everyone killed.

]]>The parity of the total number of red hats will be either 0 or 1.

The wizards divide evenly into two groups:

a) those who will work off of the assumption that the parity is 0

b) those who will work off of the assumption that the parity is 1

Note that exactly one of the groups is correct. All of the wizards in the group whose assumption is correct will live, while the others will die.

For example:

There are 22 total red hats, and 78 total blue hats. Note that the parity of red hats is 0.

Consider each wizard in group a). Each and every one of these 50 wizards sees one of two things:

– If he has a red hat, he sees 21/78. As a member of group a), he assumes that the total parity of red hats is 0. This means his hat must be red to bring the total red hats to 22. He guesses red and lives.

– If he has a blue hat, he sees 22/77. As a member of group a), he assumes that the total parity of red hats is 0. This means his hat must be red to keep the total red hats at 22. He guesses red and lives.

Consider each wizard in group b). Each and every one of these 50 wizards sees one of two things:

– If he has a red hat, he sees 21/78. As a member of group b), he assumes that the total parity of red hats is 1. This means his hat must be blue to keep the total red hats at 22. He guesses blue and dies.

– If he has a blue hat, he sees 22/77. As a member of group b), he assumes that the total parity of red hats is 1. This means his hat must be blue to bring the total red hats at 23. He guesses blue and dies.

There are 100 cases, but 101. (0, 100) / / (50-50) / / (100, 0).

Whenever they can not exchange information will be a deterministic algorithm. There are only two possible income: (reds – 1, blues) and (reds, blues – 1). Therefore all of the same color wizards choose the same color. Therefore the optimal solution is that the wizards from both colors choose the majority color.

Applying the algorithm of the majority would survive an average of 74,752 .. wizards.

(((100 + 51) / 2.) * (50 (red majority) + 50 (blue majority)) + 0 (tragic middle)) / 101 (total cases)

I’m writing the proof that is impossible to avoid total catastrophe (I can barely write in English).

Best regards

]]>On the other hand: the way the wizzards are portaited here they wouldn’t even dream of putting theire own interest over that of the group. We can take this view of wizzard psychology even further and assume that they don’t care if they live or die, as long as all of them do the same. Thus ariving at a new riddle where they want to maximize the probability of either all of them surviving or all of them dying, rather than the probabillity of all of them surviving.

Of course in this riddle the solution with leads to the highest probabillity of all of them surviving (1/2) gives also the highest probabillity of all wizzards ending up with the same fate (1). So the real new riddle is:

Can you cook up a new hat-riddle where maximizing the probabillity of all of them surviving does not yield the highest probabillity of alle of them ending up the same way?

]]>Now for the second puzzle. Since each wizzard has probabillity 1/2 of surviving, it is clear that the probability of them all surviving cannot exceed 1/2. The miracle is that with a simple strategy (which I will not spoil) this upperbound CAN be attained! In spite of the simplicity of the solution I still find this a bit of a miracle, as on first glance you would expect a probability of (1/2)^100 of all surviving.

Tanya’s nice formulation of the problem alows for a different way to phrase the miracle: suppose that the wizzard agree on following a strategy that maximizes the probabillity of all of them surviving, but some of them are secretly thinking “screw it, if I can improve my own chances of survival by changing strategy last moment, I will do so, no matter how much lives it costs.” Then all these wizzards will find out after some contemplation that there is nothing they can do to make their individual chances better and they might as well stick to the strategy that is best for the collective.

]]>If they don’t see 50, they are in 1 of 4 situations:

They see 50 red and 49 white. Their hat is red. The 49 whites are writing down red, and all will be wrong.

They see 50 red and 49 white. Their hat is white. ==

They see 49 red and 50 white. Their hat is red.

They see 49 red and 50 white. Their hat is white. The 49 reds are writing down white, and all will be wrong.

What if, “see 50 or 51” = write the opposite, and

See at least 52, write down the majority?

Well, that leads to disaster at 52-48.

Each time we add one “opposite” case, we push the disaster further and further away. But if we always “write the opposite” then we will get some pretty small (yet all positive) results, down to 100 red.

How can we measure which is better, going with opposites, or going with majority, and losing 50/50?

]]>