demo_ref_set_difference.py:
x = {"apple", "banana", "cherry"} y = {"google", "microsoft", "apple"} z = x.difference(y) print(z)
➜ begtut>python demo_set_difference.py
{'banana', 'cherry'}