Probability of an event occuring n times before its complement occurs m times Let the probability of event $E$ be $p$, and let $F$ be the complement of event $E$, so probability of event $F$ occurring is $1-p$. What is the probability of event $E$ occurring $n$ times before event $F$ occurs $m$ times?    
 A: We make the assumption that the outcomes of the trials are independent. 
Imagine repeating the experiment $n+m-1$ times. Then exactly one of the following happens: (i) $E$ occurs at least $n$ times or (ii) $F$ occurs at least $m$ times.
So we want the probability that in $n+m-1$ trials, $E$ happens $n$ or more times.
The probability of exactly $k$ occurrences of $E$ is
$$\binom{n+m-1}{k}p^k(1-p)^{n+m-1-k}.$$
For the required probability, add up from $k=n$ to $k=n+m-1$. 
Another way: We used the standard "trick" of imagining that the game continues for the full $n+m-1$ times even if a player has already "won." But we can make an alternate more complicated analysis. We find the probability that $E$ "wins" by finding the probability that $E$ gets her final win in the $n+k$-th game, where $k$ ranges from $0$ to $m-1$.
The probability that $E$ "wins the series" in round $ n+k$ is calculated as follows. She needs exactly $n-1$ wins in the first $n+k-1$ trials, and then a win on the $n +k$-th. The probability of this is 
$\binom{n+k-1}{n-1}p^{n-1}(1-p)^k p$. Add up from $k=0$ to $k=m-1$. We get
$$\sum_{k=0}^{m-1}\binom{n+k-1}{n-1}p^n(1-p)^k.$$
For estimates, particularly because estimation for the binomial is well-develped, the formula of the first answer is more useful. 
A: So E happens n times and F happens m-1 times.  THus the maximum number of trials that can occur are n+m-1 and the minimum number of trials is of course n since we can have all successes.  Thus, P(E occuring n times before M occurs m times is)
$$\sum_{k=n}^{m+k-1}{\binom{m+n-1}{k}p^k(1-p)^{m+n-1-k}}$$
