Sub topic 6
Counting 'Neither' with the Complement
This chapter assumes you know set notation, the universal set, the four basic operations, two-set Venn diagrams, and the formula n(A∪B) = n(A) + n(B) − n(A∩B). The aim here is to count the people or objects that belong to none of the named sets, and to use that count to recover the other regions.
Why 'neither' needs its own treatment
CAT problems often give you a total and ask about people who do not fall into any listed group. Examples are students who study neither Maths nor Physics, customers who bought neither product, or employees who speak none of the languages. The group is easy to overlook because it sits outside every circle in the Venn diagram. It is still part of the universal set, so it still counts toward the total.
The core idea is the complement. For a universal set U and a set A, the complement A′ contains every element of U that is not in A. For a union A∪B, the complement (A∪B)′ contains every element that is in neither A nor B.
The key identity
Because every element of U is either in A∪B or outside it, the two parts add up to the total:
n(U) = n(A∪B) + n((A∪B)′)
Rearranged, this gives two working forms:
- n(neither) = n(U) − n(A∪B)
- n(A∪B) = n(U) − n(neither)
Combined with the two-set formula, you can write the full relationship in one line:
n(U) = n(A) + n(B) − n(A∩B) + n(neither)
This is one equation with four quantities. If you know any three, you can find the fourth. That is the main skill of this chapter.
A = {1, 2, 3, 4}
B = {3, 4, 5}
U = {1, 2, 3, 4, 5, 6}
union = A | B
neither = U - union
print(neither) # {6}
print(len(U) == len(union) + len(neither)) # TrueWhere 'neither' sits in the diagram
Draw a rectangle for U, with two overlapping circles inside it. The four regions are:
| Region | Meaning | Symbol |
|---|---|---|
| Only A | in A, not in B | A − B |
| Both | in A and in B | A∩B |
| Only B | in B, not in A | B − A |
| Neither | in U, outside both circles | (A∪B)′ |
The rectangle is what makes 'neither' visible. If you draw only circles, you have no place to put the group, and you will probably misuse the total. Always draw the rectangle and write the total beside it.
Worked example 1: finding the overlap
A class of 100 students has 60 who study Maths and 50 who study Physics. 15 study neither. How many study both, and how many study only one subject?
- Students who study at least one subject: 100 − 15 = 85.
- Apply the formula: 85 = 60 + 50 − both, so both = 110 − 85 = 25.
- Only Maths: 60 − 25 = 35.
- Only Physics: 50 − 25 = 25.
Check: 35 + 25 + 25 + 15 = 100. The four regions add up to the total.
total = 100
n_a = 60 # study Maths
n_b = 50 # study Physics
neither = 15
union = total - neither # 85
both = n_a + n_b - union # 25
only_a = n_a - both # 35
only_b = n_b - both # 25
print(union, both, only_a, only_b) # 85 25 35 25The order matters. You subtract 'neither' first to get the union, and only then use the inclusion-exclusion formula. Reversing the steps is the most common source of wrong answers.
Worked example 2: finding the 'neither' count
In a survey of 200 people, 120 like tea, 90 like coffee, and 40 like both. How many like neither?
- Union: 120 + 90 − 40 = 170.
- Neither: 200 − 170 = 30.
Here the unknown is the last term, so the calculation runs directly from the formula.
Worked example 3: working with percentages
In a town, 55% of residents read newspaper X, 45% read newspaper Y, and 20% read neither. What percentage read both?
- Percentage who read at least one: 100 − 20 = 80.
- Both: 55 + 45 − 80 = 20.
So 20% read both. When the data is in percentages, the universal set is 100%. You do not need the actual population unless the question asks for a count.
Choosing the unknown
Most 'neither' problems are the same equation with a different unknown. The table shows which step to use.
| You are given | You need | Method |
|---|---|---|
| n(U), n(A), n(B), n(A∩B) | neither | Union by formula, then n(U) − union |
| n(U), n(A), n(B), neither | both | Union = n(U) − neither, then A + B − union |
| n(U), n(A∩B), neither, n(A) | n(B) | Union = n(U) − neither, then B = union − A + both |
| n(A), n(B), both, neither | n(U) | Union by formula, then add neither |
Wording that signals the complement
The word 'neither' is not the only signal. These phrases all describe the region outside both circles:
- "do not like either X or Y"
- "like none of the two"
- "play no sport" (when two sports are listed)
- "did not buy A and did not buy B"
Other phrases look similar but mean something different:
- "Do not study Maths" means the complement of A alone. That includes people who study only Physics as well as those who study neither.
- "Study at most one subject" means only A, only B, or neither. It excludes both.
- "Study at least one subject" is the union, so it excludes 'neither'.
total = 100
n_a, n_b, both, neither = 60, 50, 25, 15
not_a = total - n_a # 40: only B plus neither
at_most_one = total - both # 75: everything except both
at_least_one = total - neither # 85
print(not_a, at_most_one, at_least_one) # 40 75 85The complement of "both" is not "neither". Not being in both sets means being in at most one of them.
Common errors
- Treating the total as the union. If a problem says 100 people were surveyed and some like neither, the union is smaller than 100. Using 100 as the union makes the overlap too large.
- Forgetting to draw the rectangle. Without it, the 'neither' group has nowhere to go.
- Reading "not A" as "neither". The complement of A alone includes the part of B outside A.
- Subtracting the overlap twice. Once the formula has removed n(A∩B), do not subtract it again when computing 'only' regions. Use A − both once for each.
- Assuming a nonzero overlap. A problem may give numbers where the overlap is zero, and 'neither' then equals the total minus the sum of the two sets.
Consistency checks
Run these before you accept an answer:
- Every region must be zero or positive. A negative 'only A' means the data is inconsistent, or you made an arithmetic slip.
- The four regions must add to n(U).
- The overlap cannot exceed the smaller set, so both ≤ min(n(A), n(B)).
- The union cannot exceed the total, so n(A) + n(B) − both ≤ n(U).
def check(total, n_a, n_b, both, neither):
only_a = n_a - both
only_b = n_b - both
regions = [only_a, both, only_b, neither]
return all(r >= 0 for r in regions) and sum(regions) == total
print(check(100, 60, 50, 25, 15)) # True
print(check(100, 60, 50, 10, 15)) # False: regions sum to 50+10+40+15 = 115The second call fails because the regions sum to 115, which exceeds 100. A CAT option that would produce such a diagram can be eliminated at once.
A link to minimum and maximum overlap
The complement also tells you how far the overlap can move. With 'neither' fixed at 0, the union is at most the total, which forces a minimum overlap of n(A) + n(B) − n(U). Allowing a larger 'neither' lowers that minimum. The chapter on minimum and maximum overlap develops this fully, but the same equation drives it.
Exercise
In a group of 150 employees, 80 use Bus, 70 use Train, and 30 use both. How many use neither? Then find how many use exactly one of the two.
Show answer
Union = 80 + 70 − 30 = 120, so neither = 150 − 120 = 30. Only Bus = 80 − 30 = 50 and only Train = 70 − 30 = 40, so exactly one = 90. Check: 50 + 30 + 40 + 30 = 150.
Exercise
In a college of 500 students, 65% play cricket, 40% play football, and 15% play neither. What percentage play both, and how many students play only football?
Show answer
At least one sport: 100 − 15 = 85%. Both = 65 + 40 − 85 = 20%. Only football = 40 − 20 = 20% of 500 = 100 students.
Exercise
Of 60 people, 35 do not like tea and 28 do not like coffee. Every person likes at least one of the two drinks. How many like both?
Show answer
Likes tea = 60 − 35 = 25 and likes coffee = 60 − 28 = 32. Neither = 0, so union = 60. Both = 25 + 32 − 60 = −3, which is impossible. The data is inconsistent: if everyone likes at least one drink, the two sets must cover all 60 people, but 25 + 32 = 57 is less than 60.