You have $10,000 dollars to place a double-or-nothing bet on the Yankees in the World Series (max 7 games, series is over once a team wins 4 games).
Unfortunately, you can only bet on each individual game, not the series as a whole. how much should you bet on each game, so that, if the yanks win the whole series, you expect to get 20k, and if they lose, you expect 0?
Basically, you know that there may be between 4 and 7 games, and you need to decide on a strategy so that whenever the series is over, your final outcome is the same as an overall double-or-nothing bet on the series.
Solution
This probably isn’t the cleanest solution, but…
a dynamic-programming type solution is:
(1) Create a 5×5 matrix P.
So, P[i,j] holds your pile of money when the yanks have won i games and the mets have won j games.
initialize P[4,j] := 20 for j from 0 to 3 initialize P[i,4] := 0 for i from 0 to 3
fill P in bottom-right to top left by averaging bottom and right adjacent cells:
P[i,j] := (P[i+1,j]+P[i,j+1]) / 2
(2) Make another 5×5 matrix, B, which represets your bet at any-time.
So, B[i,j] represents your bet when the yanks have won i games and the Mets j games.
fill this top-left to bottom right by:
B[i,j] = P[i+1,j] – P[i,j]
(3) Look in matrix B for your bet at any time.
The final matricies are:

2026 Update: Probability Series and Expected Value
World Series-style probability puzzles (what is the probability that team A wins a best-of-7 series given per-game win probability p?) test your ability to compute probability distributions over sequential dependent events. This appears in quant firm interviews and data science roles.
The mathematical setup: Team A wins the series if they win 4 games before team B. The probability is the sum of binomial probabilities over all ways A can win in exactly 4, 5, 6, or 7 games.
from math import comb
def series_win_probability(p, games_to_win=4):
"""
Probability that team A wins a best-of-(2k-1) series.
p: probability A wins any individual game.
games_to_win: number of wins needed (4 for best-of-7).
"""
total_prob = 0.0
max_games = 2 * games_to_win - 1
for final_game in range(games_to_win, max_games + 1):
# A wins their final game, and won exactly (games_to_win - 1) of the previous (final_game - 1) games
prev_wins = games_to_win - 1
prev_games = final_game - 1
prob = comb(prev_games, prev_wins) * (p ** prev_wins) * ((1-p) ** (prev_games - prev_wins)) * p
total_prob += prob
return total_prob
for p in [0.5, 0.55, 0.6, 0.7]:
prob = series_win_probability(p)
print(f"p={p:.2f}: P(win series) = {prob:.4f}")
Key insight: Even with a significant per-game advantage (60% win rate), team A only wins about 71% of series. More games reduce variance — a best-of-7 is more “fair” than a best-of-1. This principle applies to A/B testing: more observations reduce variance in your effect size estimate.