Boy or Girl Paradox Calculator
The boy or girl paradox asks: if a family has two children and at least one is a boy, what is the chance both are boys? The answer is either 1/2 or 1/3 depending on exactly how the information was obtained - a surprisingly deep distinction. This calculator covers all three main variants: the classic problem, the day-of-week extension (at least one boy born on Tuesday gives 13/27), and the general named-attribute form. Select a variant, set the parameters, and see the full probability breakdown with worked steps.
What is the boy or girl paradox?
The boy or girl paradox (also called the two-child problem) was popularised by Martin Gardner in his 1959 Scientific American column. It presents a deceptively simple question: a family has two children and you are told at least one is a boy - what is the probability both are boys? Most people answer 1/2 instinctively, but a careful analysis of all equally-probable outcomes gives 1/3. Both answers are correct under different interpretations, which is why the problem is classified as a paradox. The resolution lies in precisely specifying how the information was obtained.
The 1/3 answer explained
Start by listing all equally-probable outcomes for two children: boy-boy (BB), boy-girl (BG), girl-boy (GB), and girl-girl (GG), each with probability 1/4. The statement "at least one is a boy" eliminates GG, leaving three outcomes. Only BB satisfies "both are boys", so P(both boys | at least one boy) = 1 out of 3 = 1/3. This reasoning applies when you imagine surveying a large number of two-child families and selecting only those with at least one boy. Among that selected group, exactly one-third will be boy-boy families.
The 1/2 answer and why both are correct
The 1/2 answer applies when you randomly meet one child from a two-child family and that child happens to be a boy - you have not inspected the whole family, just sampled one child at random. Under this sampling model, Bayes theorem gives P(both boys | one randomly chosen child is a boy) = 1/2. The two interpretations differ in what the observation process was: exhaustive family survey (giving 1/3) vs. random individual sampling (giving 1/2). Both computations are mathematically correct given their respective assumptions.
The day-of-week extension and the general formula
In 2010 Gary Foshee posed a sharper version: "I have two children. One is a boy born on a Tuesday. What is the probability I have two boys?" The answer is 13/27, which lies between 1/3 and 1/2. The formula for any attribute with probability epsilon (e.g. epsilon = 1/7 for a specific day) is P(BB | at least one boy with attribute) = p^2 * (2*epsilon - epsilon^2) / (p^2 * (2*epsilon - epsilon^2) + 2*p*q*epsilon), which simplifies at p = q = 0.5 to (2 - epsilon) / (4 - epsilon). As epsilon approaches 0 (ever-rarer attribute), the answer approaches 1/2. As epsilon approaches 1, the answer approaches 1/3. The Tuesday result (epsilon = 1/7) gives (2 - 1/7) / (4 - 1/7) = (13/7) / (27/7) = 13/27.
Key results at a glance (equal sex ratio p = 0.5)
| Variant | Known information | P(both boys) | Why |
|---|---|---|---|
| Ordered (older=boy) | Older child is a boy | 1/2 = 50% | Independent birth, birth order pins one child |
| Classic (survey) | At least one is a boy (whole family checked) | 1/3 = 33.33% | 3 outcomes remain; BB is 1 of 3 |
| Random meeting | One randomly chosen child is a boy | 1/2 = 50% | Bayes with random selection |
| Day of week | At least one boy born on Tuesday | 13/27 = 48.15% | Rarer attribute narrows identity |
| Month of birth | At least one boy born in January | 23/47 = 48.94% | 2*12-1=23, 4*12-1=47 |
| Day of year | At least one boy born on Jan 1 | 729/1459 = 49.97% | Approaches 1/2 as slots grow |
All values assume each child is independently a boy with probability 0.5. The source of information determines the answer.
Frequently asked questions
Why does the boy or girl paradox have two different correct answers?
Because the two answers correspond to two different probability models. The 1/3 answer arises when you survey both children and report "at least one boy" - a constraint on the family as a whole. The 1/2 answer arises when you randomly encounter one child who turns out to be a boy - a random sample from the family. Both models are internally consistent; the paradox highlights that the same English sentence ("at least one is a boy") is ambiguous about which model applies.
How does the Tuesday-born-boy variant give 13/27?
Specifying that the boy was born on a Tuesday (probability 1/7 for any given day) creates a rarer event. With equal sex ratios, the formula (2 - epsilon) / (4 - epsilon) gives (2 - 1/7) / (4 - 1/7) = (13/7) / (27/7) = 13/27 = approximately 48.1%. The rarer the attribute, the closer the answer gets to 1/2, because knowing a very specific fact about one child almost uniquely identifies that child, making the problem behave more like the "older child is a boy" case.
What happens as the attribute becomes extremely rare?
As the attribute probability epsilon approaches 0, the formula (2 - epsilon) / (4 - epsilon) approaches 2/4 = 1/2. Intuitively, a nearly-unique attribute (such as a specific birthday) essentially singles out one particular child, making the situation equivalent to "the identified child is a boy, what is the other?" - which gives 1/2 because the two children are independent.
Does the sex ratio assumption matter?
Yes. The classic 1/3 answer assumes each child is independently a boy with probability exactly 1/2. If boys are more common (say p = 0.6), then P(BB | at least one boy) = 0.36 / (1 - 0.16) = 0.36 / 0.84 = approximately 42.9%, which is closer to 1/2. The calculator lets you adjust the boy probability to see how the answer changes.
What is the Bayes theorem version of this calculation?
Using Bayes theorem: P(BB | at least one boy) = P(at least one boy | BB) * P(BB) / P(at least one boy). P(at least one boy | BB) = 1 (both are boys, so certainty), P(BB) = 1/4, and P(at least one boy) = 3/4 (eliminating GG). This gives 1 * (1/4) / (3/4) = 1/3. The random-meeting version uses a different normalization: P(at least one boy | BB) = 1, P(BB) = 1/4, but P(randomly-chosen child is a boy) = 1/2, giving 1/4 / (1/2) = 1/2.