Inclusion-exclusion principle
Counting and combinatorics (advanced) · Mathematics
Study notes
Q: In a class of 50: 30 like Maths, 25 like Science, 12 like both. How many like at least one? |M∪S| = |M| + |S| - |M∩S| = 30 + 25 - 12 = 43. (The 12 were counted twice - subtract once!) Like neither: 50 - 43 = 7.