.
1. In a class of 30 students, 20 students like mathematics, 14 students like computer science, 6 students like neither.
How many students like both mathematics and computer science?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
20 + 14 - x = 30-6,
34 - x = 24,
x = 34 - 24 = 10.
Answer. 10 students like both mathematics and computer science.
For details see the lesson
- Counting elements in sub-sets of a given finite set
in this site.