Riddle #847

cleanlogicstory

100 men are in a room, each wearing either a white or black hat. Nobody knows the color of his own hat, although everyone can see everyone else's hat. The men are not allowed to communicate with each other at all (and thus nobody will ever be able to figure out the color of his own hat). The men need to line up against the wall such that all the men with black hats are next to each other, and all the men with white hats are next to each other. How can they do this without communicating? You can assume they came up with a shared strategy before coming into the room.
The men go to stand agains the wall one at a time. If a man goes to stand against the wall and all of the men already against the wall have the same color hat, then he just goes and stands at either end of the line. However, if a man goes to stand against the wall and there are men with both black and white hats already against the wall, he goes and stands between the two men with different colored hats. This will maintain the state that the line contains men with one colored hats on one side, and men with the other colored hats on the other side, and when the last man goes and stands against the wall, we'll still have the desired outcome.
85.04 %
56 votes

Similar riddles

See also best riddles or new riddles.

cleanstoryclever

In classic mythology, there is the story of the Sphinx, a monster with the body of a lion and the upper part of a woman. The Sphinx lay crouched on the top of a rock along the highroad to the city of Thebes, and stopped all travellers passing by, proposing to them a riddle. Those who failed to answer the riddle correctly were killed. This is the riddle the Sphinx asked the travellers: "What animal walks on four legs in the morning, two legs during the day, and three legs in the evening?"
This is part of the story of Oedipus, who replied to the Sphinx, "Man, who in childhood creeps on hands and knees, in manhood walks erect, and in old age with the aid of a staff." Morning, day and night are representative of the stages of life. The Sphinx was so mortified at the solving of her riddle that she cast herself down from the rock and perished.
92.84 %
478 votes
cleanlogictricky

Sam is talking to his lawyer in jail. They are very upset because the judge has refused to grant bail. At the end of the conversation Sam is allowed to leave the jail. Why?
Sam is visiting his lawyer, who had been arrested and jailed.
87.22 %
97 votes
logiccleansimple

Two soldiers, William and Ethan, are assigned to guard a bridge, which connects the West and East sides of the Great Kingdom. Each soldier is ordered to stand at an end of the bridge to make sure no criminals cross. On one side of the bridge stands William, watching over the West side of the kingdom, and making sure no shady characters try to cross the bridge. Ethan stands on the other side of the bridge, facing the East side of the kingdom with his rifle at the ready in case any criminals try to pass across. "Any criminals today?" William asks. Ethan rolls his eyes. "What do you think?" he asks. "You roll your eyes too much," William says. How could William tell that Ethan was rolling his eyes?
William is on the east side of the bridge, facing the West side of the kingdom, while Ethan is on the west side of the bridge, facing the East side of the kingdom. So William and Ethan are facing each other, and can see each other's faces.
86.91 %
43 votes
logiccleansimpleclever

A man needs to send important documents to his friend across the country. He buys a suitcase to put the documents in, but he has a problem: the mail system in his country is very corrupt, and he knows that if he doesn't lock the suitcase, it will be opened by the post office and his documents will be stolen before they reach his friend. There are lock stores across the country that sell locks with keys. The only problem is that if he locks the suitcase, he has no way to send the key to his friend so that the friend will be able to open the lock: if he doesn't send the key, then the friend can't open the lock, and if he puts the key in the suitcase, then the friend won't be able to get to the key. The suitcase is designed so that any number of locks can be put on it, but the man figures that putting more than one lock on the suitcase will only compound the problem. After a few days, however, he figures out how to safely send the documents. He calls his friend who he's sending the documents to and explains the plan. What is the man's plan?
The plan is this: 1. The man will put a lock on the suitcase, keep the key, and send the suitcase to his friend. 2. The friend will then put his own lock on the suitcase as well, keep the key to that lock, and send the suitcase back to the man. 3. The man will use his key to remove his lock from the suitcase, and send it back to the friend. 4. The friend will remove his own lock from the suitcase and get to the documents. Search: Man-in-the-middle attack
86.91 %
43 votes
simplelogicmathcleverclean

An infinite number of mathematicians are standing behind a bar. The first asks the barman for half a pint of beer, the second for a quarter pint, the third an eighth, and so on. How many pints of beer will the barman need to fulfill all mathematicians' wishes?
Just one.
86.69 %
53 votes
logicclean

An archeologist claims he found a Roman coin dated 46 B.C. in Egypt. How much should Louvre Museum pay for the coin? Note: Roman coins can really be found in Egypt
Nothing. That coin is as phony as a three dollar bill. In 46 B.C., they wouldn't have known how many years before Christ it was.
86.69 %
53 votes
interviewlogiccleansimple

You are standing before two doors. One of the path leads to heaven and the other one leads to hell. There are two guardians, one by each door. You know one of them always tells the truth and the other always lies, but you don’t know who is the honest one and who is the liar. You can only ask one question to one of them in order to find the way to heaven. What is the question?
The question you should ask is "If I ask the other guard about which side leads to heaven, what would he answer?" It should be fairly easy to see that irrespective of whom do you ask this question, you will always get an answer which leads to hell. So you can chose the other path to continue your journey to heaven. This idea was famously used in the 1986 film Labyrinth. Here is the explanation if it is yet not clear. Let us assume that the left door leads to heaven. If you ask the guard which speaks truth about which path leads to heaven, as he speaks always the truth, he would say "left". Now that the liar , when he is asked what "the other guard (truth teller) " would answer, he would definitely say "right". Similarly, if you ask the liar about which path leads to heaven, he would say "right". As the truth teller speaks nothing but the truth, he would say "right" when he is asked what "the other guard( liar ) " would answer. So in any case, you would end up having the path to hell as an answer. So you can chose the other path as a way to heaven.
86.69 %
53 votes