Alternating Die-Roll Game: Optimal Accept/Reject Strategy
Company: Jane Street
Role: Data Scientist
Category: Software Engineering Fundamentals
Difficulty: hard
Interview Round: Technical Screen
Two players, A and B, play the following game with a fair 21-sided die whose faces are labeled with the integers $-10, -9, \ldots, 9, 10$ (one integer per face, each face equally likely).
Player A moves first. On a player's turn, that player rolls the die, observes the face value $v$, and then chooses one of two actions:
- **Accept.** The game ends immediately, and the opposing player pays the roller $v$. (If $v$ is negative, this means the roller pays the opponent $|v|$.)
- **Reject.** Nothing is paid, and the turn passes to the other player, who now rolls and faces exactly the same accept/reject choice.
Turns alternate this way indefinitely until some player accepts.
What is the optimal strategy for each player, and what is the expected payoff to A when both players play optimally?
```hint Where to start
After any rejection, the roles simply swap and the remaining game looks **identical** to the original one. Look for a *stationary* strategy — and ask whether A's and B's decision rules should really differ at all.
```
```hint Value recursion
Let $V$ be the expected payoff, under optimal play, to whichever player is *about to roll*. Rejecting hands your opponent a position worth $V$ to them (so worth $-V$ to you). Write $V$ as an expectation over the roll of the better of accepting and rejecting, and solve the resulting fixed-point equation.
```
```hint Common pitfall
"Accept anything $\ge 0$" feels natural but is **not** optimal. Compare taking a small guaranteed loss now against the expected cost of handing your opponent the move.
```
### Constraints & Assumptions
- The die is fair: each of the 21 integer values $-10$ through $10$ has probability $1/21$, and successive rolls are independent.
- The game is zero-sum: whatever the accepting player receives, the other player pays.
- There is no bound on the number of turns, no discounting, and no cost to reject.
- Both players are risk-neutral expected-value maximizers, and both play optimally (each knows the other is rational).
### Clarifying Questions to Ask
- Is every face equally likely, and are successive rolls independent of earlier ones?
- When B accepts, does A pay B the face value — i.e., is the game fully symmetric under a role swap?
- Is there any limit on the number of rounds, or any per-round cost or time discounting?
- Can a player accept a negative value, and does that mean the roller pays out of pocket?
- Are we maximizing expected value (risk-neutral), or should risk aversion factor into the strategy?
### What a Strong Answer Covers
- Recognizing the stationary, symmetric structure: after any rejection the opponent faces the identical game, so the continuation value is the same at every turn and both players share one decision rule.
- Formulating the mover's expected payoff as a fixed-point equation and deriving a threshold (accept/reject) policy from it.
- Handling the discrete faces correctly: identifying the integer cutoff, checking the threshold is self-consistent, and computing the exact game value.
- Sanity checks: indifference reasoning at the boundary, comparison against the naive threshold-at-zero policy, and an argument that the game terminates with probability 1.
### Follow-up Questions
- How do the strategy and the game value change if the roll is continuous, uniform on $[-10, 10]$?
- Suppose each rejection costs the rolling player a fee $c > 0$. How does that shift the thresholds and the value?
- What happens if every face is positive — say the faces are $1$ through $20$? What does that reveal about where the accept/reject tension actually comes from?
- How would you verify your closed-form answer numerically?