Definition
Plain language
A counting rule that adds up overlapping groups and subtracts the overlaps so nothing is double-counted.
As stated in the literature
A combinatorial identity for computing the size of a union by summing individual set sizes and subtracting pairwise intersections, with higher-order corrections.
Why it matters: It's a basic counting tool underlying many probability and combinatorics arguments, including derivations of pass@k-style estimators.
For example, to count students taking math or physics, you add the math students and the physics students and then subtract the ones taking both, so they're not counted twice.
Heard on the show
“The model writes out a multi-step solution — set up the inclusion-exclusion principle, count multiples of each, subtract overlaps, give a final answer.”Episode 026 — What RL Actually Does to Language Models, at the Token Level