Home > Riddles > The thousand bottles poisoned

The thousand bottles poisoned

Master playsLevel 4/5

Rarely does such a short problem open up such a big idea. Here it is not whoever tries the most who wins, but rather whoever converts a single round of experiments into coded information.

You have 1000 bottles of wine. One of them is poisoned, and a single drop is enough to kill a rat exactly 24 hours later.

You have 10 lab rats and you can only do one round of testing. You can prepare a mixture for each rat with drops from several bottles.

How do you reliably identify the poisoned bottle in a single 24-hour cycle?

Hints

Show hints
  1. In a single round, each rat is not only used to taste a bottle: it is used to provide a yes or no.
  2. Make each bottle have its own pattern of rats testing it.
  3. Number the bottles from 0 to 999 and write each number in binary with 10 bits.

Solution

Show full solution

Answer: use the 10 rats as the 10 bits of a binary code. Number the bottles from 0 to 999. Each number can be written in binary with 10 bits, because: $$
2^{10}=1024.

$$ Assign each rat to one of those 10 binary positions. For each bottle, look at its number in binary: if a position has a 1, you give a drop from that bottle to the corresponding rat; If there is a 0, that rat does not taste that bottle. For example, bottle 13 is written in binary with 10 bits as: $$

0000001101.

$$ That means that bottle is included in the mix of the rats corresponding to the three 1's of that code. If we number the positions from right to left, rats 1, 3 and 4 would die. After 24 hours, each dead rat scores a 1 and each live rat scores a 0. The entire pattern of deaths forms a 10-bit binary number. If the observed pattern was: $$

0000001101,
$$ We would read that number in binary and we would get 13. Therefore, the poisoned bottle would be number 13. Since 10 bits allow us to distinguish 1024 different patterns, they are enough to accurately identify one bottle out of 1000.

Related riddles

Keep practicing

If you enjoyed this one, try more pure-logic riddles, explore this theme, browse the full archive, or read the riddle-solving guide.

Next: The hundred boxes numbered →