Skip to content
LeetQuant

Medium · Probability & Combinatorics · Numerical · ~8 min · #1

Waiting for Two Heads in a Row

Real interview · Goldman Sachs, Morgan Stanley +1

You flip a fair coin repeatedly. What is the expected number of flips until you see two heads in a row (HH) for the first time?

Constraints

  • •

    Flips are independent with P(H)=P(T)=12P(H) = P(T) = \tfrac12.

Hints · 0 of 3 shown

Worked solution

Give the problem an honest attempt first, then reveal the full explanation.

Reported in interviews

Candidate-reported and unverified; the firm may phrase it differently or no longer ask it. The wording here is our own paraphrase, and the solution was written and checked independently of any answers posted at the source.

Related questions

Concepts

First-step analysisMarkov chainsLinearity of expectation

Relevant for

Quant TraderQuant ResearcherDesk Quant