Sum of 12 Before Two Consecutive 7s
Two fair dice are rolled repeatedly and the sum of the two faces is recorded after each roll. Player A wins if a sum of $12$ appears before two consecutive rolls both show a sum of $7$. Player B wins if two consecutive $7$s appear before any $12$.
What is the probability that A wins?
Hints
- Per roll, $P(12) = 1/36$, $P(7) = 6/36$, and anything else has probability $29/36$. Anything else resets B's progress.
- Set up a Markov chain with two transient states: 'no pending 7' and 'the last roll was a 7'. Write the win probability from each state.
- With $x$ = P(A wins | no pending 7) and $y$ = P(A wins | last roll was 7): $x = \tfrac{1}{36} + \tfrac{6}{36}y + \tfrac{29}{36}x$ and $y = \tfrac{1}{36} + \tfrac{29}{36}x$.
Worked Solution
How to Think About It: A's target is a single roll; B's target is a two-roll pattern that can be interrupted. The natural state variable is "is B halfway there?" Condition on the next roll from each state and solve two linear equations.
Quick Estimate: From scratch, the next "decisive" event is a 12 (probability $1/36$ per roll) or a 7 followed immediately by another 7 (roughly $6/36 \cdot 6/36 = 1/36$ per pair of rolls, but the first 7 also gives A an extra shot at a 12). So the race is close to even with a slight edge to A.
Formal Solution:
*Step 1 -- States and roll probabilities.* Per roll: $P(12) = \tfrac{1}{36}$, $P(7) = \tfrac{6}{36}$, $P(\text{other}) = \tfrac{29}{36}$. Let $x$ be the probability A wins from state $S$ (last roll was not a 7, or the game just started) and $y$ the probability A wins from state $T$ (last roll was a 7).
*Step 2 -- First-step equations.*
From $S$: a 12 wins for A, a 7 moves to $T$, anything else stays in $S$:
$$x = \frac{1}{36}\cdot 1 + \frac{6}{36}\,y + \frac{29}{36}\,x.$$
From $T$: a 12 wins for A, a 7 wins for B (second consecutive 7), anything else returns to $S$:
$$y = \frac{1}{36}\cdot 1 + \frac{6}{36}\cdot 0 + \frac{29}{36}\,x.$$
*Step 3 -- Solve.* From the first equation, $\tfrac{7}{36}x = \tfrac{1}{36} + \tfrac{6}{36}y$, i.e. $7x = 1 + 6y$. Substituting $y = \tfrac{1 + 29x}{36}$:
$$7x = 1 + \frac{6(1 + 29x)}{36} = 1 + \frac{1 + 29x}{6} \quad\Longrightarrow\quad 42x = 6 + 1 + 29x \quad\Longrightarrow\quad 13x = 7,$$
so $x = \tfrac{7}{13}$ and $y = \tfrac{6}{13}$.
*Step 4 -- Interpretation.* Being one 7 into B's pattern costs A only $1/13$ in win probability, because the next roll is far more likely to be a reset than a second 7.
Answer: $P(\text{A wins}) = \dfrac{7}{13} \approx 0.538$.
Intuition
A single 7 is six times as likely as a 12, but B needs two 7s in a row while A needs only one 12, and any non-7 roll in between wipes out B's progress. Netting those effects out gives A a modest edge, $7/13 \approx 54\%$. Two-state first-step analysis is the standard tool for "pattern X before pattern Y" questions (it is the same machinery behind Penney's game and expected waiting times for patterns), and the reset structure is exactly what makes consecutive-event patterns harder to complete than their raw frequency suggests.