TASK DEFINITION: In this task, you are given two sets, and you need to count the number of elements at the intersection of two given sets.  A Set is shown by two curly braces and comma-separated numbers inside, like {1, 2, 3}. The intersection of two given sets is the largest set which contains all the elements that are common to both sets. To find the intersection of two given sets, A and B is a set consisting of all the elements common to both A and B.
PROBLEM: Set1: '{2, 5, 7, 8, 11, 12, 16, 18}', Set2: '{4, 5}'. How many elements are there in the intersection of Set1 and Set2 ?

SOLUTION: 1

PROBLEM: Set1: '{2, 4, 8, 15, 16, 18}', Set2: '{8, 5, 15}'. How many elements are there in the intersection of Set1 and Set2 ?

SOLUTION: 2

PROBLEM: Set1: '{7}', Set2: '{4, 6, 10, 11, 12, 13, 17, 20}'. How many elements are there in the intersection of Set1 and Set2 ?

SOLUTION:
0