Previous Post: Next Post:
Python #8-Sets in Python Python #10-Dictionaries in Python
Set operations are performed by set operators....
Union:
Union of A and B is the set of all things that are members of A and B.
Intersection:
Intersection is the set of all things that intersect with A and B.
Try it 2:
Difference (A-B):
Difference is the set of all elements in A and not in B.
Try it 3:
Difference (B-A):
Difference is the set of all elements in B and not in A.
Try it 4:
Symmetric Difference:
Symmetric Difference is the set of elements which are either are in sets but not in intersection.
Try it 5:
Python #8-Sets in Python Python #10-Dictionaries in Python
What are set operations ?
Set operations is defined as performing operation with two data sets for finding comparing, intersections of the elements .
Set operations are performed by set operators....
Union:
Union of A and B is the set of all things that are members of A and B.
Try it 1:
Intersection is the set of all things that intersect with A and B.
Try it 2:
Difference (A-B):
Difference is the set of all elements in A and not in B.
Difference (B-A):
Difference is the set of all elements in B and not in A.
Try it 4:
Symmetric Difference:
Symmetric Difference is the set of elements which are either are in sets but not in intersection.
Try it 5:
Have any doubts? Don't forget to Comment..!
Thanks and Regards,
Tech Bird
Comments