Measuring and timing puzzles
GAME · Chapter 514 min readAsked at Jane Street, Optiver, SIG, IMC
Assumes Logic puzzles: information bounds and common knowledge.
After this lesson you should be able to
- Measure a quantity you have no instrument for by combining the constraints you do have.
- Recognise when a puzzle is really an arithmetic identity in disguise.
- Schedule a set of moves to minimise the worst case rather than the first case.
This family gives you crude instruments and asks for a precise answer: ropes that burn unevenly, jugs with no markings, a clock with no numbers. Every one is solved the same way — stop trying to measure the thing directly and find an operation that combines what you have into what you want.
Proposition 5.1
Combine the constraints, do not refine the instrument
You cannot make an uneven rope burn evenly and you cannot mark a jug. What you can do is run two constraints at once — two ends of the same rope, two jugs against each other, two hands of the same clock — so that their difference or their sum is the quantity you were asked for.
Holds when
- Ask what operations the objects allow, not what the objects measure.
- Halving is almost always available: two ends of one rope, or one jug poured into another.
- If the target is not reachable by those operations, say so and say why — that is also an answer.
Why lighting both ends is the whole trick. A rope that takes an hour to burn from one end takes half an hour lit from both, however unevenly it burns: the two flames between them consume the whole rope, and they meet when the total consumed is all of it. Nothing about the rate mattered. That is the pattern to look for — an operation whose answer does not depend on the thing you were not told.
Example 5.2
Forty-five minutes from two ropes
You have two ropes and a lighter. Each rope burns through in exactly minutes, but neither burns at a constant rate. Measure minutes.
Show the worked solutionHide the worked solution
Worked solution
- Formula
- Substitute
- SolveRope A is gone. Rope B has 30 minutes of burn left.
- The remaining rope now burns from both ends.
- Answer
Sanity check. Both ropes are fully consumed and no rate was ever assumed, which is the test of a correct answer here.
Example 5.3
The follow-up you will get
Same two ropes. Measure minutes without waiting the first . And what is the full set of times two such ropes can measure?
Show the worked solutionHide the worked solution
Worked solution
- Formula
- Substitute
- SolveA ends at 30; light B’s other end then.
- Fifteen arrives at , not at : you cannot have it sooner with two ropes.
- Answer
Sanity check. Saying which times are *not* reachable is the part that separates a candidate who solved the puzzle from one who remembered it.
Example 5.4
Four litres from a three and a five
You have an unmarked -litre jug, an unmarked -litre jug and a tap. Measure exactly litres.
Show the worked solutionHide the worked solution
Worked solution
- Formula
- Substitute
- SolveTwo litres left in the five.
- The three-jug holds 2 and has room for 1.
- One litre leaves the five.
- Answer
Sanity check. Any amount that is a multiple of and at most is reachable, so had to be possible before any pouring was attempted.
The rest of this lesson is in Premium
You have read the opening. 11 more sections follow, including 6 worked examples and 3 quick checks.
Nothing is charged for 7 days, and you can cancel before then. Or read Arithmetic that survives a clock in full, free.