Katkat

Analyze HT vs HH stopping-time probabilities

UpstartData Scientist · Technical Screen

Last updated

This question evaluates understanding of discrete probability, stopping-time analysis, pattern occurrence in Bernoulli sequences, derivation of PMFs and expectations, and the ability to generalize results to biased coins.

We repeatedly flip a fair coin until either the pattern HT appears (A wins) or the pattern HH appears (B wins), whichever occurs first. Ties cannot occur. 1) Compute P(A wins) and P(B wins) exactly. 2) For m ≥ 2, derive the probability mass function of the stopping time: P(A wins at flip m) and P(B wins at flip m). 3) Compute the expected stopping time E[T]. 4) Extend part (1) to a biased coin with P(H)=p and provide closed-form expressions for P(A wins) and P(B wins). 5) Validate your results by simulation (≥ 10^6 trials) and compare empirical PMFs to theory.