The previous version indeed proved simple; now a medium one (I think)
The (same) premise: A number of people stands on a line playing a hat guessing game
- they may not move during the game, they can only look straight ahead (each person in a direction along the line, i.e. right or left depending on their facings)
- they all wear a yellow, a red or a green hat.
- they see all people in front of them
- they do not know their own hat
- they do not know anything about the configuration behind them, except which people are there, and what is deduced from the content of the statements
- all statements are provably true for the person uttering them
Anna says: The person directly before the person directly before me wears a red hat
Bob says: The person directly before the person directly before me wears a green hat
then Dennis says: Ernest does not know the color of his hat
then Ernest says: I know the color of my hat
- What is the color of Ernest's hat?
- Please also provide a valid configuration of people.