Dear list,
consider python :
>>> a = set(['a', 'b', 'c'])
>>> b = set(['b', 'c', 'd'])
>>> a & b
{'b', 'c'}
>>> a | b
{'b', 'a', 'd', 'c'}
>>> a - b
{'a'}
>>> a ^ b
{'a', 'd'}
vs Sage :
sage: a = set(['a', 'b', 'c'])
sage: b = set(['b', 'c', 'd'])
sage: a & b
{'b', 'c'}
sage: a | b
{'a', 'b', 'c', 'd'}
sage: a - b
{'a'}
sage: a ^ b
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-10-7c22c32c86c9> in <module>
----> 1 a ** b
TypeError: unsupported operand type(s) for ** or pow(): 'set' and 'set'
sage: a = Set(['a', 'b', 'c'])
sage: b = Set(['b', 'c', 'd'])
sage: a & b
{'b', 'c'}
sage: a | b
{'d', 'b', 'c', 'a'}
sage: a - b
{'a'}
sage: a ^ b
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-16-7c22c32c86c9> in <module>
----> 1 a ** b
TypeError: unsupported operand type(s) for ** or pow(): 'Set_object_enumerated_with_category' and 'Set_object_enumerated_with_category'
Is the non-overloading of the ^
operator intentional (and, if so, for which reason ?) or an oversight (a. k. a. bug) ?
Sincerely,