Gambler's Ruin on a Fair Coin

Probability · Medium · Free problem
A gambler starts with $\$k$ and repeatedly bets $\
$ on a fair coin flip -- heads they win $\
$, tails they lose $\
$. The game ends when their bankroll hits $\$n$ (they win) or $\$0$ (they're ruined). What is the probability the gambler reaches $\$n$ before going broke?

Open the full interactive solver, hints, and worked solution →