>>>var = 0
>>>var += 1
>>>var
1
def increment(i)
i += 1
return i
i = increment(i) + increment(i)
class inc:
def __init__(s,p):
s.p = p
def __pos__(s):
s.p += 1
return s.p
def __add__(s,p):
s.p += 1
return s.p - 1
def __repr__(s):
return '%s' % s.p
i = inc(2)
q = ++i
q == 3; i == 3
q = i + 1
q == 3; i == 4