There are 1000 dwarves in Dwarfland. Now as you know, dwarves are born with either red or white hats on.
The dwarves in Dwarfland love to party. Every night, they all flock to the same club to dance the night away.
One day, a sign is posted at the club: "NO RED-HATTED DWARVES ALLOWED". A certain number of days pass, after which all of the white-hatted dwarves are in attendance,and none of the reds.
How did the red hats know not to come?
- The number of red and white-hatted dwarves need not be equal. There are at least 1 of each color.
- There are no reflections or mirrors in Dwarfland (i.e. the dwarves can't see the color of their own hat), and no dwarf can reveal through direct or indirect means the color of another dwarf's hat.
- There is NO COMMUNICATION among dwarves
- No white-hatted dwarf ever misses a night of partying