relative speed of incremention syntaxes (or "i=i+1" VS "i+=1")

Terry Reedy tjreedy at
Mon Aug 22 04:11:46 CEST 2011

On 8/21/2011 7:41 PM, Chris Angelico wrote:

> Agreed. If Python needed a faster alternative to "a=a+1", then I would
> recommend an "" call or something

But looking up the method name, creating a bound method wrapper, and 
making the call would probably be slower than the syntax;-).

Terry Jan Reedy

More information about the Python-list mailing list