100 Balls, 10 Buckets, 1 Single-Use Scale
Posted by Mr. ANSI Pants | Filed under Challenge of the Month
[We join our hero, Captain Constructor, atop the tallest turret of Doctor Destructor's hidden hideout: Fallacy Fortress...]
Dr. Destructor: You’re too late, Constructor! Before the next clock cycle, all of those mortals you call friends will be destroyed! And your little dog, too! [Maniacal laughter...]
Cptn. Constructor: Close your handle, Destructor. Just tell me how to interrupt the detonation kernel … er … process … sequence … thing.
Dr. Destructor: The sequence is perfectly synchronized and it cannot be pre-empted! Unless, of course, you are able to correctly identify the set of slightly-heavier-than-the-rest spheroids. But it is a task that is surely intractable to your puny single-core mind.
Cptn. Constructor: YOUR FACE IS SINGLE-CORE! [Our hero clears his throat, embarrassed. He is not generally given to such base language. Quickly he recovers his composure.] Tell me more about these spheroids.
Dr. Destructor: Over here you will find I have sorted 100 spheroids into 10 buckets. Each bucket holds 10 spheroids, as you can plainly see. 90 of these spheroids all weigh 1 gram each. The other 10 weigh 1.01 grams each and they have been placed all together in the same bucket. You should also have noticed by now that all 100 spheroids are visually indistinguishable from one another. Shall I go on? Your stack is beginning to look overflowed.
Cptn. Constructor: I have stack space you could never even dream of. continue;
Dr. Destructor: Immediately next to the buckets I have placed a scale. The scale has been badly damaged from overuse. I keep telling that furry PHP elephant he’s too big! Never mind that, though. I assure you that the scale is still perfectly accurate. However, it only has one good measurement left in it.
Cptn. Constructor: What does all of this have to do with the spheroids?
Dr. Destructor: It should be quite clear that to interrupt the sequence of destruction, you must identify which bucket contains the heavier spheroids. You may take any combination of spheroids you like from these 10 buckets, place your selection in this empty bucket labelled “this.EmtpyBucket”, and place “this.EmptyBucket” (which at that point will no longer be empty) on the scale. The scale will tell you the weight and you must then tell me which of the 10 buckets contains the heavier spheroids.
Cptn. Constructor: Truly, you have a dizzying intellect.
Dr. Destructor: Wait till I get going! Where was I?
[Join us next time for the exciting conclusion...]
[?]
Tags: thought puzzles
Comments are closed.