I recently learned about
The Hat Puzzle, which is a surprisingly tough little conundrum that goes like this: N people walk into a room and a hat is placed on each person's head. Each hat is either red or blue, and the chances that any given hat is red are 1 in 2. Each person can see the colours of everyone else's hat, but not the colour of their
(
Read more... )
Comments 2
The short explanation is that because the Hamming codes are perfect, all of the 2^n assignments of hats are either a codeword or within 1 flipped hat of a codeword. If you assign everyone a bit in the word, the algorithm is "if what I see could be a codeword, I set my bit so that it's not a codeword". Else, I pass. The only case where everyone passes is if you're on a codeword, with probability 2^k/2^n which ends up being 2^(-r) e.g. 1/(n+1).
Reply
That's very clever. Thanks for explaining!
Reply
Leave a comment