Worked example (N = 20). At 19 pumps, the surviving possibilities are equally likely, so the probability of surviving one more pump is ½ and E(pump) = ½ × 20 = 10, clearly worse than banking 19. At 19 with a one-in-three burst probability, E(pump) = ⅔ × 19 ≈ 12.67, still worse. Working backwards, the two curves cross at 10 pumps: that is the break-even point under a uniform prior on [1, 20], where risking one more pump and cashing out have equal expected payoff. Below 10, pumping is rational; above 10, banking is.
# Expected value of one more pump under a uniform prior on [1, max_limit]
def expected_value(current_pumps, max_limit=20):
prob_success = (max_limit - current_pumps - 1) / (max_limit - current_pumps)
return prob_success * (current_pumps + 1)
# Find the crossover point where pumping stops beating an immediate cash-out
for i in range(1, 15):
ev = expected_value(i)
verdict = "PUMP" if ev > i else "CASH"
print(f"Pump {i}: EV = {ev:.2f} vs Cash = {i} -> {verdict}")
The same analysis in Julia, following Koot's original approach:
using Plots, Distributions
belief = Uniform(1, 21) # uniform prior on the burst point
ev_pump(i) = (i + 1) * (20 - i) / (21 - i) # expected value of one more pump
scatter(ev_pump, 0:20, labels = "Pump")
scatter!(i -> i, 0:20, labels = "Cash") # curves cross at i = 10
Three caveats before you use this at a real assessment or a real cashier:
- The uniform prior is an assumption of convenience. Change the distribution (Poisson, truncated normal, colour-conditioned) and the break-even point moves.
- The single-balloon model ignores the exploration budget. With 39 balloons you can afford to spend several learning colour thresholds; with one, you cannot.
- In a commercial gambling product the return-to-player percentage and volatility are set by the operator's mathematics, not by your prior. No stopping rule converts a negative expected value into a positive one.
That third point is the one people skip, so it bears repeating in plain words: a good rule limits how fast you lose, not whether the edge belongs to the house.