难度:+++
这是ob的原题:
你手边有一个有左右两个托盘的特殊天平,这个天平可以显示哪边放的物品重以及重多少克。比如左边放10克的砝码,右边放11克的砝码,那么天平会显示右托盘重1克。
给你N袋小球,每袋装有10个小球,其中只有一个袋子中的小球全部为次品,其余N-1的袋子中的小球全为正品。所有的袋子和小球外观相同,所有正品小球质量相同,所有次品小球的质量也相同,且正品比次品的重,但不知究竟重多少克。
现在允许你称三次小球,然后你要判断出那个袋装的是次品。问:N最大为多大时,你仍能找出装次品的袋子。解释你的称球方案。
这个问题里已知坏球较轻。在经典12球问题里,坏球的轻重不知道,称3次可以找出坏球并知其轻重。如果另外有一个好球或不需要求出轻重,13个球也可以。如果另外有一个好球并且不需要求出轻重,最多可以称14个球。
现在把这两个问题结合起来,也就是在ob的题里改成不知道坏球轻重,还是称3次找出坏球口袋并确定坏球是轻还是重。N最大是多少?如果另外有一个好球呢?如果不需要知道轻重呢?
好题 ,送您一盏fzy口中的阿拉丁的神灯 奇怪,我回来后咋没见着fzy呢?
|
I assume that the scale is able to weigh bags of balls. N=15; Set 15 = B1,B2,B3-----,B15. i) Weigh two sets of balls: B1...B7, and B8...B14. If the two sets of balls weigh the same, then B15 is the bag of light balls. If not, weigh the lighter set of bags again. Let's assume that B1...B7 is the lighter group. ii) Weigh B1...B3 and B4...B6. If the two groups weigh the same, then B7 is the bag of light balls. If not, weigh the lighter side again. Let's assume that B1...B3 is the lighter group. iii) Weigh B1 and B2; if they weigh the same, then B3 is the bag of lighter balls. If not, the lighter one is the bag of light balls. |
N=27; Set 27 = B1, B2, B3-----, B27. i) Weigh two sets of balls: B1...B9, and B11...B18.
If the two sets of balls weigh the same, then ii) Weigh B19…B21, and B22…B24. If the two groups weigh the same, then iii) Weigh B25 and B26. Done. If not, weigh the lighter set of bags again. Let's assume that B19...B21 is the lighter group. iii) Weigh B19 and B20. Done. If the two sets of balls do not weigh the same. Let’s assume that B1…B9 is the lighter group. ii) Weigh B1...B3 and B4...B6. If the two groups weigh the same, then iii) Weigh B7 and B8. Done. If not, weigh the lighter side again. Let's assume that B1...B3 is the lighter group. iii) Weigh B1 and B2. Done. |
欢迎光临 珍珠湾ART (http://art.zhenzhubay.com/) | Powered by Discuz! X3 |