There’s more than just the possibility of blue or brown eyes. In an xkcd variant of the blue-eyed islander problem, a new villager with green eyes shows up & tells the others that he sees someone with blue eyes. The green-eyed villager & the other brown-eyed villagers have no idea (each individually) what their own eye color is.
Let’s do a variant that you can play at home. Everyone picks a card from the standard deck & without looking at it sticks it on their forehead. Everyone else can see your card, but you can’t. Let’s say everyone happens to have drawn a red card. Now someone else, someone not playing the game, comes up & says “I see a red card.”
Do you know what color card you have? Of course not, unless you’re the only one playing. You know everyone else has a red card, but you haven’t heard anything to indicate that your card matches theirs. (And your situation is identical to everyone else’s, so it doesn’t matter whose perspective we choose.)
This problem is logically similar to the blue-eyed islander problem.
Now the outsider asks us if we know what color card we have. If there is only one person playing (n=1) then we immediately say yes. We have the red card. But for n>1, the first person says “I don’t know.”
If n=2, the first person saying they don’t know tells us, what we did not know before, that they also see a red card. Then the second person knows they have a red card.
For n=3, we know that if there were only 2 red cards, the second person would have known their card color, so after 2 “I don’t know” answers, the 3rd person knows their card must be the 3rd red card.
This continues by induction. If there are n red cards, then after n-1 “I don’t know” answers, the nth person, who can only see n-1 other red cards & knows that the (n-1)th person would have known their card if there were only those n-1 red cards, now knows that their own card must be the nth (& last) red card.
In the case of the blue-eyed islanders, each day that passes with nothing happening is equivalent to one “I don’t know.” The inaction itself is a statement of epistemic uncertainty. Since each blue-eyed islander can see n-1 blue-eyed islanders, they know that it would take n-1 days for them to reach certainty if there were n-1 blue-eyed islanders. But when nothing happens after n-1 days, they know for certain that there must be more than that. Since they can see everyone but themselves, they conclude, inescapably, that they themselves must be the additional nth blue-eyed islander.
The xkcd version of the problem has islanders who discover their own eye color leave by ferry instead of killing themselves. It is rather pleasanter than the traditional version.