loading...

re: Intersection, union and difference of Sets in Python. VIEW POST

TOP OF THREAD FULL DISCUSSION
re: Actually the bitwise operations is completely applicable to the sets (i.e. the wiki XOR article contains Venn's diagrams). That's happening because...
 

That's happening because of the bitwise operations are applied not to the values but to their presence in the set.

Thanks for reminding me about that. I still prefer the explicit version in "day to day" code though, especially because they can be used dynamically if needed!

code of conduct - report abuse