This Week's Fiddler: May 15, 2026

Posted on May 15, 2026

Problem

We are playing hide-and-seek on four points \(O,A,B,C\). I start at \(O\). My nephew may hide at \(A\), \(B\), or \(C\).

The travel times are:

What route minimizes the time needed to find him in the worst case?

Main Solution

This is a shortest worst-case search problem on a weighted graph. Since the nephew is stationary, choosing a strategy is the same as choosing an order in which to check \(A\), \(B\), and \(C\).

There are only six possible orders. Their visit times are:

Order Visit times Worst case
\(A,B,C\)\(2,7,12\)\(12\)
\(A,C,B\)\(2,8,13\)\(13\)
\(B,A,C\)\(3,8,14\)\(14\)
\(B,C,A\)\(3,8,15\)\(15\)
\(C,A,B\)\(4,10,15\)\(15\)
\(C,B,A\)\(4,9,14\)\(14\)

The best order is therefore

\[ O \to A \to O \to B \to C. \]

This reaches \(A\) after 2 minutes, \(B\) after 7 minutes, and \(C\) after 12 minutes, so even in the worst case I find him within 12 minutes.

Answer: \( \boxed{12 \text{ minutes}} \).

This Week's Extra Credit

Now the nephew may hide only at \(A\) or \(B\), but he has a teleporter and may jump instantly between those two points as often as he likes. He must choose his entire teleport schedule in advance, though, without reacting to my movement.

What strategy minimizes the average time needed to find him, against the most difficult possible schedule?

Extra Credit Solution

The key point is that the nephew can plan around any deterministic inspection schedule. So if one location is checked earlier than the other, he can simply arrange to be at the unchecked location at that moment. To make progress, I need to make \(A\) and \(B\) equally plausible at the next inspection time.

Let:

After a miss at \(A\), I know he was at \(B\) at that instant, but from then on he can continue following his preplanned teleport schedule. The same symmetry applies after a miss at \(B\).

From the Start

Starting at \(O\), the earliest time I can possibly inspect \(B\) is 3 minutes. I can also inspect \(A\) at time 3 by waiting 1 minute and then walking to \(A\).

So the earliest common inspection time is 3 minutes, and the right move is to randomize equally:

If one side had probability less than \(1/2\), the nephew would prefer that side. Equal probabilities are optimal.

After Missing at \(A\)

Once I am at \(A\), the earliest time I can inspect:

So the earliest common inspection time is 5 minutes later. I can either go to \(B\), or wait 1 minute and return to \(A\). Again I should randomize equally, so

\[ V_A = 5 + \frac{1}{2}\max(V_A,V_B). \]

The extra term appears because at that inspection time the nephew can choose the less likely location and force a miss with probability \(1/2\), after which the game continues from the worse of the two resulting states.

After Missing at \(B\)

From \(B\), the earliest time I can inspect:

So the earliest common inspection time is 6 minutes later, giving

\[ V_B = 6 + \frac{1}{2}\max(V_A,V_B). \]

Solving the Recurrence

Clearly \(V_B > V_A\), so the maximum in both equations is \(V_B\). Therefore

\[ V_B = 6 + \frac{V_B}{2}, \]

hence

\[ V_B = 12. \]

Then

\[ V_A = 5 + \frac{12}{2} = 11. \]

Finally, from the start we have the same logic with common inspection time 3:

\[ V_O = 3 + \frac{1}{2}\max(V_A,V_B) = 3 + \frac{12}{2} = 9. \]

Extra credit answer: \( \boxed{9 \text{ minutes}} \).

The optimal strategy is to keep re-equalizing the next possible inspection time. From \(O\), inspect \(A\) or \(B\) at time 3 with equal probability. After any miss, do the same thing again from your current location at the earliest future time when both locations can once more be inspected with equal probability.

More Fiddlers: Previous | Next

Back to blog