Exercise 1 solution q = 0.01 p = 1 - q carriers = 2 * p * q affected = q * q print(round(carriers, 4), affected) n = 200000 sens, spec = 0.95, 0.98 carr = n * carriers tp = carr * sens fp = (n - carr) * (1 - spec) print(round(carr), round(tp), round(fp)) print(round(tp / (tp + fp), 3)) print(round(carriers * carriers * 0.25, 6), round(carriers * carriers, 6)) Output: 0.0198 0.0001 3960 3762 3921 0.49 9.8e-05 0.000392 Reading it: about 2% of people are carriers but only 1 in 10,000 is affected, so a recessive condition is mostly carried silently (Genetics and Heredity Fundamentals 8). Even with a test that is 95% sensitive and 98% specific, roughly half of the positive results are false alarms, because carriers are rare. A positive result is a reason for a confirming test, not a final answer. The chance that both partners are carriers, and that the child is affected, is tiny for a random couple, but it is only the starting point: family history changes the numbers.