Skip to content
Vamshi Jandhyala

Books · The Fiddler: Solutions

Chapter 44

Can You Sprint to the Finish?

You and one rival approach the finish line. Each of you privately assesses your legs as a number uniform on [0,1][0,1], then decides whether to sprint. A sprinter always beats a non-sprinter; if both sprint, the fresher legs win; if neither sprints, it is a coin flip. Your rival’s manager has announced that the rival will sprint whenever their legs feel at least 0.50.5. Playing optimally, what is your chance of winning?

The Fiddler, Zach Wissner-Gross, July 25, 2025(original post)

Solution

Sprinting dominates: against a non-sprinter you win for certain (versus a coin flip if you also hold back), and against a sprinter you win with probability equal to your chance of fresher legs (versus a sure loss if you hold back). So the optimal rule is to always sprint, whatever your legs. With your legs yU[0,1]y\sim U[0,1] and the rival sprinting only when their legs o12o\ge\tfrac12, P(win)=12rival holds back1+12 ⁣ ⁣1/21 ⁣ ⁣2(1o)do=12+1214=5862.5%.\begin{aligned} P(\text{win})&=\underbrace{\tfrac12}_{\text{rival holds back}}\cdot 1 +\tfrac12\!\!\int_{1/2}^{1}\!\!2\,(1-o)\,do\\ &=\tfrac12+\tfrac12\cdot\tfrac14=\frac58\approx\boxed{62.5\%}. \end{aligned}

The computation

Run the race: you always sprint, the rival sprints only on legs 12\ge\tfrac12. Against a holding rival you win; against a sprinting one the fresher legs win. The win rate lands on 58\tfrac58.

import numpy as np
rng = np.random.default_rng(0); M = 8_000_000
y = rng.random(M); o = rng.random(M); op = o >= .5        # you always sprint
win = np.where(~op, 1.0, (y > o)*1.0)                     # vs non-sprinter win; else fresher legs
print(round(win.mean(), 5))                              # 0.625 = 5/8

Extra Credit

Now three riders race. Both rivals sprint at 0.50.5 or better. Your manager fills the blank in “sprint if your legs feel at least ” with a number chosen uniformly at random in [0,1][0,1]. Before you draw that threshold and test your legs, what is your chance of winning?

Solution

Average over the random threshold tt, your legs yy, and the rivals’ legs. Since tU[0,1]t\sim U[0,1], you sprint with probability yy; conditioning on the number of sprinting rivals (0,1,20,1,2 with probabilities 14,12,14\tfrac14,\tfrac12,\tfrac14, each with legs U[12,1]U[\tfrac12,1]), P(win)=14 ⁣01 ⁣(y+1y3)dy+12 ⁣1/21 ⁣y(2y1)dy+14 ⁣1/21 ⁣y(2y1)2dy=16+548+7192=5919230.7%.\begin{aligned} P(\text{win})&=\tfrac14\!\int_0^1\!\Bigl(y+\tfrac{1-y}{3}\Bigr)dy +\tfrac12\!\int_{1/2}^1\! y(2y-1)\,dy\\ &\quad+\tfrac14\!\int_{1/2}^1\! y(2y-1)^2 dy\\ &=\frac16+\frac{5}{48}+\frac{7}{192}=\frac{59}{192}\approx\boxed{30.7\%}. \end{aligned} (The source value is paywalled; this closed form is my own.)

The computation

Simulate the three-rider race directly: draw your random threshold and everyone’s legs, decide who sprints, and award the win to the sprinter with the freshest legs (a three-way coin flip when nobody sprints).

rng = np.random.default_rng(1); M = 8_000_000
t, y, o1, o2 = (rng.random(M) for _ in range(4))
ys = y >= t; s1 = o1 >= .5; s2 = o2 >= .5
legs = np.stack([y, o1, o2]); spr = np.stack([ys, s1, s2])
big = np.where(spr, legs, -1.0); anyone = spr.any(0)
youmax = (big[0] >= big[1]) & (big[0] >= big[2]) & ys
print(round(np.where(anyone, youmax*1.0, 1/3).mean(), 5))   # 0.3073 = 59/192