Sets and Venn Operations

This chapter answers the Mathematics heading on sets and Venn operations in the RRB computer-based tests: set notation, types of sets, subsets, union, intersection, difference, complement, and counting with two and three sets. It serves RRB Technician and NTPC candidates, and strengthens the Venn-diagram items in reasoning for Level-1 as well. It teaches the symbols, the counting formulas with worked numericals, the region-by-region method for three sets, and the traps that swap similar notation.

Sets and their notation

A set is a well-defined collection of distinct objects, called elements or members. We write x ∈ A for 'x belongs to A' and x ∉ A otherwise. Two ways to describe a set: the roster (tabular) form, A = {2, 4, 6, 8}, and the set-builder form, A = {x : x is an even natural number less than 10}. Order and repetition do not matter: {1, 2, 3} = {3, 2, 1, 2}.

TypeMeaningExample
Empty (null) set ∅no elements{x : x is a prime between 23 and 29}
Singletonexactly one element{0}
Finite / infinitecountable end / no end{1, 2, 3} / natural numbers
Equal setssame elements{1, 2} and {2, 1}
Disjoint setsno common element{1, 2} and {3, 4}
Universal set Uthe set that contains all elements under discussionintegers 1 to 10
⚠️ Zero, empty and {∅} are different
∅ has no element, so n(∅) = 0. {0} has one element, the number zero, so n({0}) = 1. {∅} also has one element, the empty set. The empty set is a subset of every set, but {∅} is not the empty set.

Number systems are written as standard sets: N natural numbers, W whole numbers (N together with 0), Z integers, Q rational numbers, R real numbers, with N ⊂ W ⊂ Z ⊂ Q ⊂ R.

Subsets and the power set

A is a subset of B, written A ⊆ B, if every element of A is in B. It is a proper subset (A ⊂ B) if A ≠ B as well. Two facts always hold: ∅ ⊆ A and A ⊆ A. The power set P(A) is the set of all subsets of A. If A has n elements, then the number of subsets is 2ⁿ, the number of proper subsets is 2ⁿ − 1, and the number of non-empty proper subsets is 2ⁿ − 2.

Worked example. A = {a, b, c, d} has 2⁴ = 16 subsets and 15 proper subsets. A set with 3 elements has 8 subsets, and the 8 are: ∅, three singletons, three pairs and the set itself. The reasoning: each element is either in or out of a subset, 2 choices per element, so 2 × 2 × ... (n times) = 2ⁿ.

  • {1, 2} ⊆ {1, 2, 3}: true. 2 ∈ {1, 2, 3}: true. 2 ⊆ {1, 2, 3}: not valid, since 2 is an element, not a set.
  • If A ⊆ B and B ⊆ A then A = B.
🧠 ∈ for elements, ⊆ for sets
Ask 'what is on the left?' An object takes ∈; a set takes ⊆. This one test settles most notation questions.

Union, intersection, difference, complement

Take A = {1, 2, 3, 4, 5, 6}, B = {4, 5, 6, 7, 8} and universal set U = {1, 2, ..., 10}.

OperationMeaningResult for the sets above
Union A ∪ Bin A or B or both{1, 2, 3, 4, 5, 6, 7, 8}
Intersection A ∩ Bin both A and B{4, 5, 6}
Difference A − Bin A but not in B{1, 2, 3}
Difference B − Ain B but not in A{7, 8}
Complement A′in U but not in A{7, 8, 9, 10}
Symmetric difference A △ Bin exactly one of A, B{1, 2, 3, 7, 8}
  • A − B = A ∩ B′. The part of A outside B.
  • Commutative: A ∪ B = B ∪ A; A ∩ B = B ∩ A. But A − B ≠ B − A in general.
  • Distributive: A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C); A ∪ (B ∩ C) = (A ∪ B) ∩ (A ∪ C).
  • De Morgan: (A ∪ B)′ = A′ ∩ B′ and (A ∩ B)′ = A′ ∪ B′. Break the bar, flip the symbol.
  • Complement laws: (A′)′ = A, A ∪ A′ = U, A ∩ A′ = ∅, and U′ = ∅.

De Morgan check. U = {1, ..., 10}, A = {1, 2, 3, 4}, B = {3, 4, 5, 6}. A ∪ B = {1, ..., 6}, so (A ∪ B)′ = {7, 8, 9, 10}. Also A′ = {5, ..., 10} and B′ = {1, 2, 7, 8, 9, 10}, whose intersection is {7, 8, 9, 10}. The two sides agree.

🎯 The complement needs a universe
A′ means 'everything in U that is not in A', so the same A has different complements in different universes. If a stem does not name U, the complement cannot be computed.

Counting with two sets

The central formula is n(A ∪ B) = n(A) + n(B) − n(A ∩ B). Why subtract: the elements common to both are counted once in n(A) and once in n(B), so they have been counted twice. Useful companions: n(only A) = n(A) − n(A ∩ B); n(neither) = n(U) − n(A ∪ B); n(A △ B) = n(A) + n(B) − 2n(A ∩ B).

Worked example 1. Among 60 students, 35 play cricket, 28 play football and 10 play both. Union = 35 + 28 − 10 = 53 play at least one game. Neither = 60 − 53 = 7. Only cricket = 35 − 10 = 25. Only football = 18. Check: 25 + 18 + 10 + 7 = 60.

Worked example 2 (multiples). Among 1 to 100, 33 numbers are multiples of 3, 20 are multiples of 5, and 6 are multiples of both (that is, of 15). Multiples of 3 or 5 = 33 + 20 − 6 = 47, so 53 numbers are multiples of neither.

Least and greatest overlap. In a group of 40, 30 like tea and 25 like coffee. The overlap is smallest when the union is the whole group: 30 + 25 − 40 = 15. It is largest when the smaller set sits inside the larger: 25.

⚠️ 'Either, but not both' versus 'at least one'
'Only one of the two' is A △ B: n(A) + n(B) − 2n(A ∩ B). 'At least one' is the union. In example 1 only one game is played by 25 + 18 = 43 students, while at least one by 53.

Three sets and the region method

For three sets: n(A ∪ B ∪ C) = n(A) + n(B) + n(C) − n(A ∩ B) − n(B ∩ C) − n(A ∩ C) + n(A ∩ B ∩ C). The pairwise overlaps are subtracted, but that removes the triple overlap one time too many, so it is added back. In practice, fill the Venn diagram from the centre outward: put the triple overlap first, then each pair-only region (pair total − triple), then each only-region.

Worked example. Of 100 persons, n(A) = 50, n(B) = 40, n(C) = 30; n(A ∩ B) = 15, n(B ∩ C) = 10, n(A ∩ C) = 12; all three = 5. Union = 50 + 40 + 30 − 15 − 10 − 12 + 5 = 88, so 12 persons are in none. Regions: only A = 50 − 15 − 12 + 5 = 28; only B = 40 − 15 − 10 + 5 = 20; only C = 30 − 12 − 10 + 5 = 13; exactly two sets = (15 − 5) + (10 − 5) + (12 − 5) = 22; all three = 5. Check: 28 + 20 + 13 + 22 + 5 = 88.

RegionFormula
Only An(A) − n(A∩B) − n(A∩C) + n(A∩B∩C)
A and B onlyn(A∩B) − n(A∩B∩C)
Exactly one setsum of the three only-regions
Exactly two setssum of the three pair-only regions
🧠 Never read 'both' as 'both only'
When a stem says 'n(A ∩ B) = 15' that figure includes those also in C. If it says '15 are in A and B but not C', the triple overlap is outside the 15. Decide which reading the stem uses before filling the centre.

Exam patterns and quick checks

  • Which shaded region? Translate words: 'only A' = A − B; 'neither' = (A ∪ B)′; 'not in A' = A′.
  • Number of elements of power sets: n(P(A)) = 2ⁿ. A set with 5 elements gives 32.
  • Matching and odd-one-out: ∅, {0}, {∅} and 0 are different objects; of ∈, ⊆, ⊂, ∪, ∩ only the first three relate things, while ∪ and ∩ produce sets.
  • Sanity check: n(A ∪ B) can never exceed n(A) + n(B) or n(U), and can never be less than the larger of n(A), n(B).

Speed plan: draw a two-circle or three-circle diagram, write the known overlap in the centre first, work outward, and finish by checking that all regions add up to the total.

ℹ️ Link with reasoning
The Venn diagrams of syllogism questions show 'all', 'some' and 'no' relations; the set operations here count members. The drawings are the same, the questions differ.

Key takeaways

  • A set is a well-defined collection; order and repetition do not matter; ∅ has 0 elements, {0} and {∅} have 1 each.
  • A set with n elements has 2ⁿ subsets, 2ⁿ − 1 proper subsets; ∈ links an element to a set, ⊆ links two sets.
  • A − B = A ∩ B′, A − B ≠ B − A, and a complement exists only relative to a universal set U.
  • De Morgan: (A ∪ B)′ = A′ ∩ B′ and (A ∩ B)′ = A′ ∪ B′.
  • n(A ∪ B) = n(A) + n(B) − n(A ∩ B); neither = n(U) − n(A ∪ B).
  • For three sets subtract the pairs, add back the triple overlap, and fill the diagram from the centre outward.

Practice questions (16)

Attempt each one before opening the answer. Every explanation names the tempting wrong option as well as the right one, because that is where marks are lost.

  1. How many subsets does a set with 4 elements have?

    1. 8
    2. 15
    3. 16
    4. 12
    Show answer

    Answer: C — 16

    Each element is either in or out, so a set of 4 elements has 2⁴ = 16 subsets. The number 15 counts only the proper subsets, which leave out the set itself.
  2. Which set has exactly one element?

    1. ∅
    2. {x : x is a prime between 23 and 29}
    3. {x : x is a natural number less than 1}
    4. {∅}
    Show answer

    Answer: D — {∅}

    {∅} contains one element, the empty set. The other three have no element: there is no prime between 23 and 29, and no natural number is below 1, so each is empty.
  3. Judge these for A = {1, 2, 3}. P: 2 ∈ A. Q: {2} ⊆ A. R: 2 ⊆ A. S: ∅ ⊆ A. Which are correct?

    1. P, Q and S
    2. P and Q only
    3. P, Q, R and S
    4. Q and R only
    Show answer

    Answer: A — P, Q and S

    P, Q and S are true; R is not valid because 2 is an element, not a set, so ⊆ cannot be used with it. The choice 'P and Q only' misses that ∅ is a subset of every set.
  4. Which of the following is NOT true for every set A?

    1. ∅ is a subset of A
    2. A has at least one proper subset
    3. A is a subset of A
    4. A ∪ ∅ = A
    Show answer

    Answer: B — A has at least one proper subset

    The empty set has no proper subset, so the statement fails when A = ∅. The other three hold for every set, including the empty one.
  5. If A = {1, 2, 3, 4, 5, 6} and B = {4, 5, 6, 7, 8}, what is A − B?

    1. {7, 8}
    2. {4, 5, 6}
    3. {1, 2, 3, 7, 8}
    4. {1, 2, 3}
    Show answer

    Answer: D — {1, 2, 3}

    A − B keeps the elements of A that are not in B, namely 1, 2, 3. The set {7, 8} is B − A, and {1, 2, 3, 7, 8} is the symmetric difference.
  6. U = {1, 2, ..., 10}, A = {1, 2, 3, 4} and B = {3, 4, 5, 6}. What is (A ∪ B)′?

    1. {7, 8, 9, 10}
    2. {5, 6, 7, 8, 9, 10}
    3. {1, 2, 7, 8, 9, 10}
    4. {3, 4}
    Show answer

    Answer: A — {7, 8, 9, 10}

    A ∪ B = {1, 2, 3, 4, 5, 6}, and its complement in U is {7, 8, 9, 10}. The set {5, ..., 10} is only A′, and {3, 4} is the intersection, not a complement.
  7. Which is the correct De Morgan law?

    1. (A ∩ B)′ = A′ ∩ B′
    2. (A ∪ B)′ = A′ ∪ B′
    3. (A ∩ B)′ = A′ ∪ B′
    4. (A ∪ B)′ = A′ − B′
    Show answer

    Answer: C — (A ∩ B)′ = A′ ∪ B′

    Breaking the bar flips the symbol: the complement of an intersection is the union of the complements. Keeping the same symbol on both sides is the common slip.
  8. For sets A and B inside a universal set U, which expression equals A − B?

    1. A′ ∩ B
    2. A ∩ B′
    3. A ∪ B′
    4. (A ∩ B)′
    Show answer

    Answer: B — A ∩ B′

    A − B is the part of A outside B, which is A ∩ B′. The set A′ ∩ B is B − A, the mirror image, which is a different set unless A = B.
  9. In a class of 60, 35 play cricket, 28 play football and 10 play both. How many play neither game?

    1. 7
    2. 3
    3. 17
    4. 10
    Show answer

    Answer: A — 7

    At least one game: 35 + 28 − 10 = 53, so neither = 60 − 53 = 7. The number 17 is 60 − 43, which wrongly counts only those who play exactly one game.
  10. Among the numbers 1 to 100, how many are divisible by neither 3 nor 5?

    1. 47
    2. 53
    3. 60
    4. 52
    Show answer

    Answer: B — 53

    Multiples of 3: 33, of 5: 20, of 15: 6, so 33 + 20 − 6 = 47 are divisible by 3 or 5 and 100 − 47 = 53 by neither. The number 47 is the union, which is not what the stem asks.
  11. In a group of 40, 30 like tea and 25 like coffee, and everyone likes at least one. What is the least possible number who like both?

    1. 5
    2. 25
    3. 10
    4. 15
    Show answer

    Answer: D — 15

    With union = 40, n(A ∩ B) = 30 + 25 − 40 = 15, and any fewer would leave someone liking neither. The figure 25 is the largest possible overlap, not the least.
  12. Of 50 people, 20 speak Hindi only, 15 speak English only and 5 speak neither. How many speak both languages?

    1. 10
    2. 15
    3. 5
    4. 30
    Show answer

    Answer: A — 10

    Those who speak exactly one or neither add up to 20 + 15 + 5 = 40, so 50 − 40 = 10 speak both. The value 15 would be the English-only group read as the overlap.
  13. In a survey of 100 people, n(A) = 50, n(B) = 40, n(C) = 30, n(A ∩ B) = 15, n(B ∩ C) = 10, n(A ∩ C) = 12 and n(A ∩ B ∩ C) = 5. How many belong to none of A, B, C?

    1. 7
    2. 12
    3. 17
    4. 22
    Show answer

    Answer: B — 12

    The union is 50 + 40 + 30 − 15 − 10 − 12 + 5 = 88, so 100 − 88 = 12. Forgetting to add back the triple overlap gives a union of 83 and the wrong answer 17.
  14. Of 100 people, n(A) = 50, n(B) = 40, n(C) = 30, n(A ∩ B) = 15, n(B ∩ C) = 10, n(A ∩ C) = 12 and n(A ∩ B ∩ C) = 5 (each pair figure includes the 5 who are in all three sets). How many are in exactly two of the sets?

    1. 22
    2. 37
    3. 27
    4. 17
    Show answer

    Answer: A — 22

    Exactly two = (15 − 5) + (10 − 5) + (12 − 5) = 10 + 5 + 7 = 22. The sum 37 is the raw pair totals and counts the central 5 three times.
  15. A set A has 3 elements and a set B has 5 elements, and A ∩ B has 2 elements. How many elements are in exactly one of the two sets (A △ B)?

    1. 6
    2. 4
    3. 8
    4. 5
    Show answer

    Answer: B — 4

    n(A △ B) = n(A) + n(B) − 2 × n(A ∩ B) = 3 + 5 − 4 = 4: one element of A and three of B lie outside the overlap. The figure 6 is the union n(A ∪ B), which counts the overlap once instead of removing it.
  16. A set P has 5 elements. How many elements does its power set P(P) have?

    1. 25
    2. 10
    3. 31
    4. 32
    Show answer

    Answer: D — 32

    The power set has 2⁵ = 32 elements, each a subset of P. The figure 31 counts only proper subsets, and 25 wrongly squares 5 instead of raising 2 to the power 5.