To define a class behaviour in the following statement:
my_object[item] = ...
I know I need to define the __setitem__ method.
What method do I need to define for the following statement:
my_object[item] += ...
To define a class behaviour in the following statement:
my_object[item] = ...
I know I need to define the __setitem__ method.
What method do I need to define for the following statement:
my_object[item] += ...