- #1
- 3,381
- 463
With an example, can someone explain me what the following code would do?
In fact I am not certain I understand how the |= operator is used. (I have checked for operator overloading within the classes but there is none, so it supposedly does the default operation)
Thanks.
In fact I am not certain I understand how the |= operator is used. (I have checked for operator overloading within the classes but there is none, so it supposedly does the default operation)
Python:
objectA = ClassA(arguments)
toy_obj1 = Class(args)
toy_obj2 = Class(args)
objectA |= set([object1, object2]) #??!?
Thanks.