Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Number the balls 1-12. Then, weigh 1-4 against 5-8. We do casework on the result.
- Case 1: The scale balances. Hence, 1-8 weigh the same and the unique ball is one of 9-12. Weigh 1-3 against 9-11. We split into subcases.
- 1A: The scale balances again. Then, 12 is the unique ball. Weigh it against ball 1 to determine whether it is heavy or light.
- 1B: 9-11 are heavier. This means that one of these three balls is unique and is heavier than the rest. Weigh 9 vs 10. If one of them is heavier, that's the unique ball. Otherwise, 11 is the unique ball and is heavier than the rest.
- 1C: 9-11 are lighter. The solution here is isomorphic to 1B.
- Case 2: 1-4 are lighter. Hence, the answer is that one of 1-4 is a light ball or one of 5-8 is a heavy ball. Meanwhile, we know 9-12 are standard balls. Weigh balls 1, 5, 9, and 10 against balls 2, 3, 6, and 7.
- Case 2A: The scale balances. Then, these eight balls, as well as 11 and 12, are identical. The answer is thus either that 4 is light or 8 is heavy. Weigh 4 against 9 to determine whether 4 is light; if not, 8 must be heavy.
- Case 2B: 1, 5, 9, and 10 are lighter. In this case, we must have that 1 is light or that 6 or 7 is heavy. Weigh 6 against 7. If one is heavier, that gives us our answer. If the scale is balanced, we must have that 1 is light.
- Case 2C: 2, 3, 6, and 7 are lighter. In this case, we must have that 5 is heavy or that 2 or 3 is light. Weigh 2 against 3. If one is lighter, we're done, otherwise, we must have that 5 is heavy.
- Case 3: 1-4 are heavier. The solution here is isomorphic to Case 2.
- Note that the key motivation here, particularly for the first step, is that we have 12 * 2 = 24 possible answers and 3^3 = 27 possible outcomes for our three weightings. Hence, we need to make full use of our moves, ensuring that after each weighting, we will have a reasonable number of options for the subcases. In particular, we first weigh four balls against another four because in each of the resulting cases, we have eight possible answers. (In contrast, weighing any other number of balls in the first weighting would result in one case having more than nine possible answers, when we would only be able to distinguish among 3^2 = 9 possibilities, proving that we have to start with a 4-by-4 weighting.)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement