What exactly does += do in python?
I need to know what += does in python. It's that simple. I also would appreciate links to definitions of other shorthand tools in python.
In, Python += adds another value with the variable's value and assigns the new value to the variable. You can see the example below:-
>>> x = 3
>>> x += 2
>>> print x