There are 10 bags of coins. One bag contains all counterfeit coins weighing 1.1 grams each. Real coins weigh 1 gram. You have a digital scale that gives exact weight. With one weighing, identify the counterfeit bag.
There are 10 bags of coins. One bag contains all counterfeit coins weighing 1.1 grams each. Real coins weigh 1 gram. You have a digital scale that gives exact weight. With one weighing, identify the counterfeit bag.
Approach: Take different numbers of coins from each bag.
Take 1 coin from bag 1, 2 from bag 2, ..., 10 from bag 10. Weigh all. Extra weight = 0.1 × bag number. So weight = (1+2+...+10) + 0.1×k = 55 + 0.1k grams, where k is counterfeit bag number.
Follow-up: What if scale only compares?
Key concepts: linear combination, encoding, single measurement.