n prisoners are wearing three different coloured hats. They are in a line so that they can see the people in front of them but not behind. They will each try to guess their own hat colour and if they get it wrong they will be shot, otherwise they will be freed. The calling will begin from the back (the one who can see all the other people) and the others can also hear what the ones before them called. What is the optimal strategy that the prisoners can develop that will deterministically save the greatest number of them?

If you are feeling brave try this one.

The same scenario with infinite number of prisoners (countable of course) and two hat colours. They can't hear what the others call but I claim I can save all but finitely many of them using the axiom of choice.