On this page
When you analyse a survey—such as counting how many students read *The Hindu* versus *The Times of India*, or play cricket versus football—the totals often add up to more than the number of people asked. This happens because individuals who do both are counted twice.
The mathematical fix for this double-counting is the inclusion-exclusion principle 1. In Class 11 mathematics, this concept is introduced in the chapter on sets, giving you a reliable formula to untangle word problems without having to draw and shade a Venn diagram every single time. By understanding how the sets interact, you can handle any survey data question that appears in your exams.
What is the n(A ∪ B) formula for two sets?
In combinatorics, the inclusion-exclusion principle states that for two finite sets A and B, the number of elements in their union is given by the formula n(A ∪ B) = n(A) + n(B) − n(A ∩ B) 1.
Here is what each mathematical term means when you are reading a word problem:
n(A): The total number of elements in the first set (for example, everyone who plays football).
n(B): The total number of elements in the second set.
n(A ∩ B): The intersection, which represents the elements that belong to both A and B.
n(A ∪ B): The union, which represents the elements that belong to A, or B, or both.
Why do we have to subtract the intersection? Adding the totals of n(A) and n(B) counts the middle overlap twice. Subtracting n(A ∩ B) once corrects this overcount, leaving you with the true total 1. For example, if a question states that n(A) = 30, n(B) = 25, and n(A ∩ B) = 5, the union will contain 30 + 25 − 5 = 50 elements.
Read more about representing these groups visually in our guide to sets and relations in Class 11.
How do you solve n(A ∪ B) formula word problems?
Most Class 11 exam questions give you three of the four variables and ask you to find the missing one. Sometimes the wording can be tricky, so it helps to follow a consistent method. To solve these problems reliably, use these steps:
Define the sets: Assign a logical letter to each group. Let C be the set of people who drink coffee, and let T be the set of people who drink tea.
Translate the words into symbols: Look for specific keywords in the text. The word "and" always means intersection (∩). The word "or" always means union (∪).
Check the universal set: Read the problem carefully to see if the total number of people is the same as the union. If the problem says that everyone in the group drinks at least one beverage, then the union n(C ∪ T) is exactly the total group size. If some people drink neither beverage, the union is the total group minus the "neither" group.
Plug into the formula: Substitute the known values into the equation n(A ∪ B) = n(A) + n(B) − n(A ∩ B) and use basic algebra to solve for the unknown variable.
What is the formula for three sets?
When a third category is introduced—such as adding milk to the coffee and tea survey—the principle expands. For three finite sets A, B, and C, the formula is: n(A ∪ B ∪ C) = n(A) + n(B) + n(C) − n(A ∩ B) − n(B ∩ C) − n(A ∩ C) + n(A ∩ B ∩ C) 1.
The logic behind this longer formula remains the same as the two-set version. First, you add the sizes of the three individual sets, which overcounts the two-way intersections, so you must subtract those. However, subtracting all three of the two-way intersections removes the three-way intersection completely. Because it was added three times and then subtracted three times, you must add the three-way intersection back at the end to balance the count 1.
For more complex examples, see our walkthrough on solving three-set Venn problems.
If you keep confusing "only A" with the total for set A in these longer word problems, Fermi's AI tutor can help. When you bring a confusing survey question to the Fermi Problem Library, it doesn't just print the final number. Instead, the tutor writes on the board, draws the figure of the sets, and asks you which region corresponds to a given clue, checking your understanding before moving to the final calculation.
Read more about the history behind these diagrams in our profile on John Venn and his logic.



