Probability problem from CMU contest prep course Your sports team is playing a best-of-15 series against a single opponent. Against this opponent, your
team wins with probability 40%, unless it is behind in the series (with strictly fewer wins than losses
so far in these 15-game finals), at which point your team wins with probability 60%. What is the
probability that your team wins?
I'm not great at math so I wrote a dynamic programming algorithm to solve it. If my algorithm is correct, the answer would be 40%. I found that if the number of matches is odd, the probability that you win is always 40%, for any number of matches.
Can anyone verify this and provide a probabilistic explanation of the solution?
Thanks!
 A: Note: What's crucial here is that $0.4 + 0.6 = 1$. Otherwise, this will not work.
Let the series be denoted by an element of $ S =  \{ L, W \} ^{15}$.
Hint: Create a bijection $f: S \rightarrow S$ between matches that you won, and matches that you lost

 - If you won the series, consider all of the matches (you won more games)
 - Take that series, and 1) Swap each of the W into a L and vice versa, and 2) Reverse the game order
 - This then becomes a series that you lost (since you lost more games)

Claim: P(You win) / 40% = P(You lost ) / 60%.

 Proof: Say you won with $s$.
 For the last match that you won, you won with probability 40%.
 Now consider $f(s)$.
 For the first match that you lost, you lost with probability 60%.
 Ignoring that match in both series (which correspond to the same match), verify that the probability of the sequence happening is the same. (There's a small step here that you should verify the probabilities match up, which has to do with how the games are defined).

Corollary: P(You win) = 40%.

As an explicit example, consider a round of 5 games where $ s = WLLWW$ where you won.
Then $f(s) = LLWWL$ where you lost.
$P(s) = 0.4 \times 0.6 \times 0.6 \times 0.6 \times 0.4$.
Ignoring the last win, we get $P(s) / 0.4 = 0.4 \times 0.6 \times 0.6 \times 0.6 $.
$P(f(s) ) = 0.6 \times 0.4 \times 0.6 \times 0.6 \times 0.6 $
Ignoring the first loss, we get $ P (f(s) ) / 0.6 = 0.4 \times 0.6 \times 0.6 \times 0.6$.
Hence, the probabilities match up.
A: Here's another way to match up your wins with your losses to show that your probability of winning is 40%. Notice first that the question's descriptions of the probabilities can be stated as: Whenever the series isn't tied, the team that's behind has a 60% chance of winning, but when the series is tied your opponent has a 60% chance of winning. So the only difference between the two teams is when the series is tied.
As in Calvin Lin's answer, represent the possible histories of the series by 15-letter strings of L and W. Define a function $F$ from such histories to histories as follows. Given a history $h$, let $F(h)$ be the same as $h$ up to the last moment $M(h)$ when the series was tied. (There's at least one such moment, since it's tied at 0-0 at the start. So $M(h)$ exists.) After $M(h)$ replace every L in that part of $h$ by W and replace every W by L. So you win in $h$ iff you lose in $F(h)$. Notice also that $F(F(h))=h$ for all histories $h$. So $F$ matches up your winning histories with your losing ones.
Now compare the probability of $F(h)$ with that of $h$. Each is the product of probabilities of the individual games' outcomes conditional on the previous games. Before $M(h)$, $F(h)$ and $h$ are identical, so those conditional probabilities agree. At $M(h)$, whichever of $h$ and $F(h)$ has your team winning will have lower probability by a factor 2/3, since the series is tied at $M(h)$ (which is also $M(F(h))$).  After that, there are no more differences in the probabilities, because there are no more ties. (Remember that $M(h)$ was the last tie.) So among $h$ and $F(h)$, the one where you win at $M(h)$ has lower probability than the other, by a factor of 2/3.
But, since there are no ties after $M(h)$, the team that wins the game right after $M(h)$ will win the series, for the other team can never catch up.  So I can rewrite the last sentence of the preceding paragraph as: Among $h$ and $F(h)$, the one where you win the series has lower probability than the other, by a factor of 2/3.  That is, you win the series with probability 40%.
