Sex Ratio with a Girl-Stopping Rule

Expectation · Easy · Free problem

You stumble upon an isolated civilization in a rainforest. The culture strongly prefers daughters: every couple keeps having children until they have a girl, then stops. Assume each child is equally likely to be a boy or a girl, independently of all others.

After many generations, what fraction of the children in this society are girls?

Hints

  1. Think about what the stopping rule actually does: it decides when to stop flipping, but it can't change the probability of any individual flip. What does that imply about the sex of each child born?
  2. Count girls and boys separately. Every couple stops after exactly one girl -- so how many girls are there total? Then use $E[G] = 1/p$ for a Geometric$(p)$ variable to find the expected total number of children.
  3. With $n$ couples and a Geometric$(1/2)$ family size, each couple contributes exactly 1 girl and on average 1 boy, giving expected total children
n$. The girl proportion is $n / 2n$.

Worked Solution

How to Think About It: Your first instinct might be: "they keep having kids until they get a girl, so there must be more girls than boys." That's wrong, and a good interviewer will push you on it. The stopping rule is a decision rule applied *after* the coin flip -- it doesn't bend the coin. Every child, regardless of birth order or family context, is still a fair 50/50 draw. The stopping rule can't shift probability mass from boys to girls; it only determines when a couple exits the process. So the answer should be 1/2 before you touch any math.

Quick Estimate: Think about what a single family looks like. With probability

/2$, the couple has exactly one child: a girl. With probability
/4$, they have two children: boy then girl. With probability
/8$: boy, boy, girl. And so on. With $n$ couples, every family ends with exactly one girl -- so there are exactly $n$ girls total. The expected number of boys per couple is
/2 \cdot 0 + 1/4 \cdot 1 + 1/8 \cdot 2 + \cdots$. That sum equals 1, so there are also $n$ expected boys. Total children:
n$. Girl fraction: $n / 2n = 1/2$. The estimate is exact.

Approach: Formalize using the geometric distribution and linearity of expectation over $n$ independent couples.

Formal Solution:

Label the $n$ couples

, \ldots, n$. Couple $i$ stops after their first girl. The number of children couple $i$ has is a $\text{Geometric}(1/2)$ random variable $G_i$ (counting the girl), taking values
, 2, 3, \ldots$ with probabilities
/2, 1/4, 1/8, \ldots$

Key observations:

  1. Every couple produces exactly one girl. The stopping rule guarantees this. So the total number of girls is exactly $n$.
  1. Expected family size. $E[G_i] = 1/p = 1/(1/2) = 2$. By linearity of expectation, the expected total number of children across all $n$ couples is
n$.
  1. Boys per couple. The number of boys in family $i$ is $G_i - 1$ (all children except the final girl). So expected boys per couple $= E[G_i - 1] = 2 - 1 = 1$, and expected total boys $= n$.

The proportion of girls is:

$\frac{\text{number of girls}}{\text{total children}} = \frac{n}{n + n} = \frac{1}{2}$

This holds exactly (not just in expectation) for the girl count; for the boy count it holds in expectation. In a large population, by the law of large numbers, the actual ratio converges to

/2$.

Alternative argument via linearity: Consider any single child born in this civilization. What is the probability that child is a girl? The child's sex is determined by a fair coin flip that happens before the stopping rule is applied. The stopping rule observes the outcome and decides whether to flip again -- but it cannot change the probability of the current flip. So $P(\text{any given child is a girl}) = 1/2$, and the fraction of girls in the population is

/2$.

Answer: The proportion of girls in the population is $\boxed{1/2}$. The girl-preference stopping rule does not shift the sex ratio.

Intuition

The deeper lesson here is that stopping rules are applied to outcomes, not to probabilities. The sex of each child is determined by an independent coin flip; the couple's decision to stop is a response to that outcome, not a cause. No matter how cleverly you design a stopping rule -- stop on the first girl, stop on the second girl, stop after three boys -- you cannot systematically extract more of one outcome from a fair coin. This is sometimes called the "optional stopping" intuition in probability: you can choose when to stop, but you cannot change the underlying distribution of the tosses themselves.

This type of problem shows up in trading and risk contexts when people confuse selection effects with causal effects. For example, a desk might only report a trade if it crosses some threshold (stopping rule), which can make the reported P&L distribution look skewed -- but the underlying trade outcomes are still drawn from the same distribution. Recognizing when a filtering or stopping mechanism is operating on outcomes versus changing the generating process is a critical skill in both statistics and practical risk management.

Open the full interactive solver →