1. The Emperor You are the ruler of a medieval empire and you are about to have a celebration tomorrow. The celebration is the most important party you have ever hosted. You've got 1000 bottles of wine you were planning to open for the celebration, but you find out that one of them is poisoned. The poison exhibits no symptoms until death. Death occurs within ten to twenty hours after consuming even the minutest amount of poison. You have over a thousand slaves at your disposal and just under 24 hours to determine which single bottle is poisoned. You have a handful of prisoners about to be executed, and it would mar your celebration to have anyone else killed. What is the smallest number of prisoners you must have to drink from the bottles to be absolutely sure to find the poisoned bottle within 24 hours? Guess: Guess | Show Hint Show Solution Hint: It is much smaller than you first might think. Try to solve the problem first with one poisoned bottle out of eight total bottles of wine. Solution: 10 prisoners must sample the wine. Bonus points if you worked out a way to ensure than no more than 8 prisoners die. Number all bottles using binary digits. Assign each prisoner to one of the binary flags. Prisoners must take a sip from each bottle where their binary flag is set. Here is how you would find one poisoned bottle out of eight total bottles of wine. 1 2 3 4 5 6 7 8 Prisoner A X X X X Prisoner B X X X X Prisoner C X X X X In the above example, if all prisoners die, bottle 8 is bad. If none die, bottle 1 is bad. If A & B dies, bottle 4 is bad. With ten people there are 1024 unique combinations so you could test up to 1024 bottles of wine. Each of the ten prisoners will take a small sip from about 500 bottles. Each sip should take no longer than 15 seconds and should be a very small amount. Small sips not only leave more wine for guests. Small sips also avoid death by alcohol poisoning. As long as each prisoner is administered about a millilitre from each bottle, they will only consume the equivalent of about one bottle of wine each. Each prisoner will have at least a fifty percent chance of living. There is only one binary combination where all prisoners must sip from the wine. If there are ten prisoners then there are ten more combinations where all but one prisoner must sip from the wine. By avoiding these two types of combinations you can ensure no more than 8 prisoners die. One viewer felt that this solution was in flagrant contempt of restaurant etiquette. The emperor paid for this wine, so there should be no need to prove to the guests that wine is the same as the label. I am not even sure if ancient wine even came with labels affixed. However, it is true that after leaving the wine open for a day, that this medieval wine will taste more like vinegar than it ever did. C'est la vie. Comments (29) | Votes (1)
2. The Stark Raving Mad King A stark raving mad king tells his 100 wisest men he is about to line them up and that he will place either a red or blue hat on each of their heads. Once lined up, they must not communicate amongst themselves. Nor may they attempt to look behind them or remove their own hat. The king tells the wise men that they will be able to see all the hats in front of them. They will not be able to see the color of their own hat or the hats behind them, although they will be able to hear the answers from all those behind them. The king will then start with the wise man in the back and ask "what color is your hat?" The wise man will only be allowed to answer "red" or "blue," nothing more. If the answer is incorrect then the wise man will be silently killed. If the answer is correct then the wise man may live but must remain absolutely silent. The king will then move on to the next wise man and repeat the question. The king makes it clear that if anyone breaks the rules then all the wise men will die, then allows the wise men to consult before lining them up. The king listens in while the wise men consult each other to make sure they don't devise a plan to cheat. To communicate anything more than their guess of red or blue by coughing or shuffling would be breaking the rules. What is the maximum number of men they can be guaranteed to save? Guess: Guess | Show Hint Show Solution Hint: To solve this problem, you need to presume that each wise man can count the total number of red hats in front of them without error, that all the wise men have great attention to detail and that all the wise men care about the greater good. Solution: 99. You can save about 50% by having everyone guess randomly. You can save 50% or more if every even person agrees to call out the color of the hat in front of them. That way the person in front knows what color their hat is, and if the person behind also has the same colored hat then both will survive. So how can 99 people be saved? The first wise man counts all the red hats he can see (Q) and then answers "blue" if the number is odd or "red" if the number is even. Each subsequent wise man keeps track of the number of red hats known to have been saved from behind (X), and counts the number of red hats in front (Y). If Q was even, and if X&Y are either both even or are both odd, then the wise man would answer blue. Otherwise the wise man would answer red. If Q was odd, and if X&Y are either both even or are both odd, then the wise man would answer red. Otherwise the wise man would answer blue. There can be any number of red hats, as the following examples show... Prisoner Hat he wears Number of red hats he sees (Y) Red hats saved for sure (X) He says 1 red 6 even (Q) N/A red 2 blue 6 even 0 even blue 3 red 5 odd 0 even red 4 blue 5 odd 1 odd blue 5 blue 5 odd 1 odd blue 6 red 4 even 1 odd red 7 red 3 odd 2 even red 8 red 2 even 3 odd red 9 red 1 odd 4 even red 10 red 0 even 5 odd red Another example might also help, as this puzzle seems to trip up most people... Prisoner Hat he wears Number of red hats he sees (Y) Red hats saved for sure (X) He says 1 blue 5 odd (Q) N/A blue 2 blue 5 odd 0 even blue 3 red 4 even 0 even red 4 blue 4 even 1 odd blue 5 blue 4 even 1 odd blue 6 red 3 odd 1 odd red 7 blue 3 odd 2 even blue 8 red 2 even 2 even red 9 red 1 odd 3 odd red 10 red 0 even 3 odd red Comments (23) | Be the first to vote
3. The Fake Coin You have twelve coins. You know that one is fake. The only thing that distinguishes the fake coin from the real coins is that its weight is imperceptibly different. You have a perfectly balanced scale. The scale only tells you which side weighs more than the other side. What is the smallest number of times you must use the scale in order to always find the fake coin? Use only the twelve coins themselves and no others, no other weights, no cutting coins, no pencil marks on the scale. etc. These are modern coins, so the fake coin is not necessarily lighter. Presume the worst case scenario, and don't hope that you will pick the right coin on the first attempt. Guess: Guess | Show Hint Show Solution Hint: The balance tells you which side is heavier and which side is lighter. You can move coins around and get more information this way. Solution: 3. If you knew the fake coin was lighter, then the solution would have an easy explanation. But you do not. So.... Number the coins 1 through 12. 1. Weigh coins 1,2,3,4 against coins 5,6,7,8. 1.1. If they balance, then weigh coins 9 and 10 against coins 11 and 8 (we know from the first weighing that 8 is a good coin). 1.1.1. If the second weighing also balances, we know coin 12 (the only one not yet weighed) is the counterfeit. The third weighing indicates whether it is heavy or light. 1.1.2. If (at the second weighing) coins 11 and 8 are heavier than coins 9 and 10, either 11 is heavy or 9 is light or 10 is light. Weigh 9 against 10. If they balance, 11 is heavy. If they don't balance, you know that either 9 or 10 is light, so the top coin is the fake. 1.1.3 If (at the second weighing) coins 11 and 8 are lighter than coins 9 and 10, either 11 is light or 9 is heavy or 10 is heavy. Weigh 9 against 10. If they balance, 11 is light. If they don't balance, you know that either 9 or 10 is heavy, so the bottom coin is the fake. 1.2. Now if (at first weighing) the side with coins 5,6,7,8 are heavier than the side with coins 1,2,3,4. This means that either 1,2,3,4 is light or 5,6,7,8 is heavy. Weigh 1,2, and 5 against 3,6, and 9. 1.2.1. If (when we weigh 1,2, and 5 against 3,6 and 9) they balance, it means that either 7 or 8 is heavy or 4 is light. By weighing 7 and 8 we obtain the answer, because if they balance, then 4 has to be light. If 7 and 8 do not balance, then the heavier coin is the counterfeit. 1.2.2. If (when we weigh 1,2, and 5 against 3,6 and 9) the right side is heavier, then either 6 is heavy or 1 is light or 2 is light. By weighing 1 against 2 the solution is obtained. 1.2.3. If (when we weigh 1,2, and 5 against 3, 6 and 9) the right side is lighter, then either 3 is light or 5 is heavy. By weighing 3 against a good coin the solution is easily arrived at. 1.3 If (at the first weighing) coins 1,2,3,4 are heavier than coins 5,6,7,8 then repeat the previous steps 1.2 through 1.2.3 but switch the numbers of coins 1,2,3,4 with 5,6,7,8. Comments (72) | Be the first to vote
4. The Trainee Technician A 120 wire cable has been laid firmly underground between two telephone exchanges located 10km apart. Unfortunately after the cable was laid it was discovered to be the wrong type, the problem is the individual wires are not labeled. There is no visual way of knowing which wire is which and thus connections at either end is not immediately possible. You are a trainee technician and your boss has asked you to identify and label the wires at both ends without ripping it all up. You have no transport and only a battery and light bulb to test continuity. You do have tape and pen for labeling the wires. What is the shortest distance in kilometers you will need to walk to correctly identify and label each wire? Guess: Guess | Show Hint Show Solution Hint: Creating a single loop will only help you identify all the wires by walking 40km. You need to group them in a rather odd matrix. Solution: 20. At one end label a wire "A". Then join two wire and label them both "B', then tie three (not already joined) wires together and call them each "C"....continue until all the wires are joined together in groups of 1, 2, 3, 4, 5, etc....for a 120 strand cable. NOTES that the largest group will have 15 wires. Now walk to the other end. Using a (battery and light bulb) it is now possible, for example, to find the wire that wasn't joined to any of the others. It is similarly possible to find which wires are in a pair, which is joined in a group of 3, etc. Each time a group is found the technician should label it with the letter for the group, so the single wire is labeled 'a', the pair are each labeled "A", etc....this now matches the other end.....the letters will go up to "O". Now take "A", "B", up to "O" and join them together in a group and label each one with "15", so we have cable "A15", "B15', "C15", up to "O15". Take the second and last "B'"wire and join it with a remaining "C", "D", up to "O" and label these each "14' so we have "B14", "C14", up to "O14". Repeat this until at the end there will be a single "O" cabled labeled "O1". Now walk to the other end. Now untie all the old connections and identify the group labeled "1", "2", "3" ..."15" at which point each wire at each end has a unique classification. Alternative solution from citrog: First, tie the 120 wires together randomly in 60 pairs. Next, go to the far end, randomly label any wire 1, and connect the battery to it. Test which other wire is tied to it at the starting end, and label that wire 2. Then pick another wire other than 1 or 2, label it 3, and tie it to 2, so now the battery is connected to 1, which is tied to 2 at the other end, which is tied to 3 at the end you're at. Now test which wire is tied to 3 at the other end, and label that 4, etc. What you will wind up with is all 120 wires tied to each other in a continuous sequence. Then go back to the end you started at, leaving the battery behind, connected to wire 1. Before you untie all the wires at the starting point, label each wire so that you know which wire was paired with which. Now with all the wires untied at the starting point, test which wire is connected to the battery, and label that 1. Whichever wire was in the same pair as 1, label that 2, and then tie 1 and 2 back together. Now you can find 3, because it's tied to 2 on the far end. Once you find 3, label the wire it was tied to 4, etc. This assumes that the resistance of the wire is small enough that the battery will still light the bulb across 12,000 km of wire. Comments (14) | Be the first to vote
5. The Card Trick I ask Alex to pick any 5 cards out of a deck with no Jokers. He can inspect then shuffle the deck before picking any five cards. He picks out 5 cards then hands them to me (Peter can't see any of this). I look at the cards and I pick 1 card out and give it back to Alex. I then arrange the other four cards in a special way, and give those 4 cards all face down, and in a neat pile, to Peter. Peter looks at the 4 cards i gave him, and says out loud which card Alex is holding (suit and number). How? The solution uses pure logic, not sleight of hand. All Peter needs to know is the order of the cards and what is on their face, nothing more. Show Hint Show Solution Hint: There are only 4 suits, so there will be at least two cards of one suit, one higher and another lower. By careful selection and placement the cards can be used to encode the exact number and suit of the selected card. Solution: Pick out two cards of the same suit. Select a card for Alex where adding a number no greater than six will result in the number of the other card of the same suit. Adding one to the Ace would cycle to the beginning again and result in a Two. E.g. if you have a King and a Six of Diamonds, hand the King to Alex. The other three cards will be used to encode a number from 1 through 6. Devise a system with Peter to rank all cards uniquely from 1 to 52 (e.g. the two of hearts is 1, the two of diamonds is fourteen etc...). That will allow you to choose from six combinations, depending on where you put the lowest and highest cards. Comments (6) | Be the first to vote
6. The Warden The warden meets with 23 new prisoners when they arrive. He tells them, "You may meet today and plan a strategy. But after today, you will be in isolated cells and will have no communication with one another. "In the prison is a switch room, which contains two light switches labeled 1 and 2, each of which can be in either up or the down position. I am not telling you their present positions. The switches are not connected to anything. "After today, from time to time whenever I feel so inclined, I will select one prisoner at random and escort him to the switch room. This prisoner will select one of the two switches and reverse its position. He must flip one switch when he visits the switch room, and may only flip one of the switches. Then he'll be led back to his cell. "No one else will be allowed to alter the switches until I lead the next prisoner into the switch room. I'm going to choose prisoners at random. I may choose the same guy three times in a row, or I may jump around and come back. I will not touch the switches, if I wanted you dead you would already be dead. "Given enough time, everyone will eventually visit the switch room the same number of times as everyone else. At any time, anyone may declare to me, 'We have all visited the switch room.' "If it is true, then you will all be set free. If it is false, and somebody has not yet visited the switch room, you will all die horribly. You will be carefully monitored, and any attempt to break any of these rules will result in instant death to all of you" What is the strategy they come up with so that they can be free? Show Hint Show Solution Hint: Take a long-term perspective. Solve the puzzler for three prisoners. Solution: The team nominates a leader. The group agrees upon the following rules: The leader is the only person who will announce that everyone has visited the switch room. All the prisoners (except for the leader) will flip the first switch up at their very first opportunity, and again on the second opportunity. If the first switch is already up, or they have already flipped the first switch up two times, they will then flip the second switch. Only the leader may flip the first switch down, if the first switch is already down, then the leader will flip the second switch. The leader remembers how many times he has flipped the first switch down. Once the leader has flipped the first switch down 44 times, he announces that all have visited the room. It does not matter how many times a prisoner has visited the room, in which order the prisoners were sent or even if the first switch was initially up. Once the leader has flipped the switch down 44 times then the leader knows everyone has visited the room. If the switch was initially down, then all 22 prisoners will flip the switch up twice. If the switch was initially up, then there will be one prisoner who only flips the switch up once and the rest will flip it up twice. The prisoners can not be certain that all have visited the room after the leader flips the switch down 23 times, as the first 12 prisoners plus the leader might be taken to the room 24 times before anyone else is allowed into the room. Because the initial state of the switch might be up, the prisoners must flip the first switch up twice. If they decide to flip it up only once, the leader will not know if he should count to 22 or 23. In the example of three prisoners, the leader must flip the first switch down three times to be sure all prisoners have visited the room, twice for the two other prisoners and once more in case the switch was initially up. 2026 Edit: In the example of three prisoners, in theory the leader must flip the first switch down four times to be sure all prisoners have visited the room. In one case he flips it once in case the leader was the first in the room and the switch was already in the up position, twice more in case the first prisoner is sent into the room twice in a row, and then a fourth time to know the second prisoner was in the room at least once. In the other case he flips it twice after the first prisoner is sent into the room two times, and twice after the second prisoner was in the room two times. In practice, the leader needs only flip the switch up three times, and then only needs to observe the switch up for the fourth time, he does not really need to flip it down the fourth time. The same is true for the 23 prisoner version of the puzzle. The leader actually only needs to flip the switch up 43 times and observe down 44 times. Comments (38) | Be the first to vote
7. The Three Gods (True, False, and Random) Three gods — A, B and C — are, in some unknown order, the gods True, False and Random. True always speaks truthfully. False always speaks falsely. Random answers completely at random; each time he is asked a question he independently chooses to tell the truth or to lie. You may ask up to three yes–no questions in total. Each question must be addressed to exactly one god (the same god may be questioned more than once, and some god might not be questioned at all). Your goal is to determine which god is which. The gods understand English but will reply in their own language, in which their words for yes and no are “da” and “ja” — you do not know which word means which. Questions may depend on earlier answers; you may use the words “da” and “ja” in your questions, but of course you do not know which is which. What questions can you ask to determine the identity of each god? Show Hint Show Solution Hint: Try to build a question whose answer is predictable even if Random is the one who answers it. One classic trick is to embed one question inside another, e.g. “If I were to ask you X, would you say da?” Solution: Here is one solution: First of all, one cannot assume that a god would stay silent and not answer when faced with an impossible question, because that is not given in the question. For example, if faced with an impossible question, a god may just give a random answer, so it is best to avoid asking questions with no definitive answer. Important notes: a) You can make the false god speak the truth by adding "if I were to ask you..." in front of the main question, as the layered question cancels out his lies. b) By using "...would you say da?" as the end of a question, you can infer whether the god means yes or no in his answer, regardless of what da and ja mean: if he answers da, then he must mean yes, because even if da means no, two negatives make a positive. Similarly, if he answers ja, then he must mean no. From a) & b), it is possible to phrase any question to the true or false gods such that they tell the truth and you understand the answer. The problem lies only with the random god, so the first two questions are aimed at identifying him. Questions: 1. (to god A) If I were to ask you whether god B is the random god, would you say da? 2.1. A answers da. This means that the random god is god A, or god B, hence the next question is directed to C: If I were to ask you whether god B is the random god, would you say da? 3.1. C answers da. C is not random, so he must be telling the truth, therefore god B is random. Next question to C again: If I were to ask you whether god A is the false god, would you say da? Answers da: A is false, B is random, C is true. Answers ja: A is true, B is random, C is false. 3.2. C answers ja. A must be random. Next question to C again: If I were to ask you whether god B is the false god, would you say da? Answers da: A is random, B is false, C is true. Answers ja: A is random, B is true, C is false. 2.2. A answers ja. This means the random god is god A, or god C, so the next question is to god B: If I were to ask you whether god C is the random god, would you say da? 3.3. B answers da. C must be random. Next question to B again: If I were to ask you whether god A is the false god, would you say da? Answers da: A is false, B is true, C is random. Answers ja: A is true, B is false, C is random. 3.4. B answers ja. A must be random. Next question to B again: If I were to ask you whether god C is the false god, would you say da? Answers da: A is random, B is true, C is false. Answers ja: A is random, B is false, C is true. In summary: 1st question determines who is not random, and hence who to ask next. 2nd question determines who is random. 3rd question determines who is true and who is false. Answers: da da da...................A-False B-Random C-True da da ja....................A-True B-Random C-False da ja da....................A-Random B-False C-True da ja ja.....................A-Random B-True C-False ja da da....................A-False B-True C-Random ja da ja.....................A-True B-False C-Random ja ja da.....................A-Random B-True C-False ja ja ja......................A-Random B-False C-True This provides the answer without even knowing what da and ja mean! It is possible, though, to find the answer as well as what da and ja mean, using a much more complicated strategy.Solution contributed by Dzallen. Comments (16) | Be the first to vote
8. Sultan and His Princess A wily young man wishes to marry the princess Arlena. Unfortunately, her father, the Sultan, is opposed to the marriage and is willing to buy the young man off. The Sultan, therefore makes the young man the following offer--"You get to make one statement. If the statement is false, you will be put to death and receive none of the following three things. If the statement is true, you may have one of the following three things, but I get to choose! The three things are: (1) Arlena's hand in marriage; (2) A cup filled with extremely valuable diamonds; (3) A magic lamp with a genie (who, unfortunately, cannot do marriages)." The wily young man, however, is too wily for his future father-in-law. He makes a statement such that the only way the Sultan can keep his promise is by giving the young man Arlena's hand in marriage. What was the statement? Show Solution Solution: The young man could say, 'If you do not let me marry your daughter, I will be put to death.' If the Sultan chooses to give him the diamonds or the genie, the statement becomes true, and he must be executed, creating a paradox. Therefore, the only resolution is for the Sultan to give him Arlena's hand in marriage. Comments (15) | Be the first to vote
9. Out of 52 Cards 13 Are up and 39 Are Down and Are Mixed Out of 52 cards 13 are up and 39 are down and are mixed . How to arrange them in two decks of equal numbers of up. Condition You are sitting in a dark room and there is no light. Show Solution Solution: Separate the cards into two piles: one with 13 cards and the other with 39 cards. Flip all the cards in the pile of 13. This way, if the pile of 39 has x face-up cards, the pile of 13 will have 13-x face-up cards, and flipping it will result in both piles having x face-up cards. Comments (5) | Be the first to vote
10. Dotted Dwarfs The leader of a group of dwarfs wants to test his group. So at night he paints on the back of each dwarf a dot, either red of blue. The next morning he let's the dwarfs gather at a meeting point and tell's them the rules of the game: You may never know what the color of your own dot is. (This is accomplished by saying they may not communicate in any way or use mirrors and such) He will give them a few minutes to discuss a tactic to solve the puzzle. The goal is that the number of dwarfs with a red dot, assume this number is X, on their back gather at the same meetingpoint the number of days, X, after the start of the game. for example if there are 10 red dots, after 10 days they must gather Any other entry upon the meetingpoint of any dwarf results in failure. Now, how must every dwarf think to solve the puzzle? Show Solution Solution: Each dwarf will observe the number of red dots on the backs of the other dwarfs. If a dwarf sees Y red dots, they will assume that the total number of red dots, X, is either Y (if their own dot is blue) or Y + 1 (if their own dot is red). Therefore, they will wait for X days. If no one gathers after Y days, it indicates that they must have a red dot themselves, and they will gather on the Xth day. This way, all dwarfs with red dots will gather at the correct time. Comments (17) | Be the first to vote
11. Coins on a Chessboard A warden takes prisoner A into a room containing a chessboard, on each square of which is a coin randomly showing heads or tails. He then indicates a random square on that board. Prisoner A is given the chance to flip one coin (or none), then taken from the room, after which prisoner B is taken into the room and must say which square the warden indicated. The two prisoners may strategize beforehand, but may not communicate during the trial (except with the single coin flip). What should be their strategy? Show Solution Solution: None Comments (2) | Be the first to vote