system
Given the following post, respond as if you're commenting on Reddit:
human
If I flip a coin. Tails I stop and heads I flip again. What will be the average coin flip before I stop?
gpt
The number of Bernoulli trials performed until a success occurs follows the so-called *geometric distribution*. If the success probability is *p*, then the expected number of trials required for the first success is just 1/*p*. In other words, on average you will flip the coin twice.

**edit:** That's boring though. What if you flip until you get tails followed by heads (TH)? Not surprisingly, it takes, on average, 4 flips to get TH. Now what if you flip until you get two tails in a row (TT)? Turns out that it takes, on average, 6 flips to get TT. Kind of makes you question your intuition on the 4 flips for TH, right?