[Python-ideas] Implement __add__ for set and frozenset

Arnaud Delobelle arnodel at googlemail.com
Tue Jun 3 21:55:44 CEST 2008


On 3 Jun 2008, at 20:12, Mattias Engdegård wrote:

> Arnaud Delobelle <arnodel at googlemail.com> writes:
>
>>    A ^ (B ^ B) = A  but  (A ^ B) ^ B = A | B
>
> No, symmetric set difference is associative.
>

Sorry, I don't know what came over me.  It's obviously associative  
because an element is in the symmetric difference if it is in an odd  
numbers of sets.

-- 
Arnaud




More information about the Python-ideas mailing list