1000 bottles of wine
This was a very interesting question but I could only get partway through. I numbered each bottle of wine from 1-1000. Then, with 10 rats, I knew that we could group the bottles into groups of 100's, with 1 group of 100 for each rat. So rat 1 would have bottles 0-100, rat 2 would have bottles 101-200, and so on. In this scenario, I could test 100 bottles of wine with 1 rat so that I would be left with 900 bottles of 'safe' wine. But this isn't what the question ask. But then I was stuck.
I have since learned that we can solve the problem using binary numbers. To start, label the bottles in base 10 representation 1-1000 again, but this time, also label them in binary. The rats represent the digits of a binary number: 1, 2, 4, 8, 16, 32, 64, 128, 256, 512.
For each bottle of wine, pour one drop of wine for each 1 in it's binary code in the appropriate rat. After an hour, the dead rats/live rats will reveal a pattern showing which bottle of wine has the poison.
I have since learned that we can solve the problem using binary numbers. To start, label the bottles in base 10 representation 1-1000 again, but this time, also label them in binary. The rats represent the digits of a binary number: 1, 2, 4, 8, 16, 32, 64, 128, 256, 512.
For each bottle of wine, pour one drop of wine for each 1 in it's binary code in the appropriate rat. After an hour, the dead rats/live rats will reveal a pattern showing which bottle of wine has the poison.
Comments
Post a Comment