Augmented Assignement (was: Re: PEP scepticism)

Courageous jkraska1 at
Mon Jul 2 08:15:10 CEST 2001

>> def f(x):
>> x = x + (1,2,3)
>> print x

>A vast improvement: clear, unambiguous, and correct.  I can safely pass a
>list as an argument and not have it modified behind my back.

Eek. I finally got what everyone is talking about.

x += (1,2,3)

... is not the same as...


That's just plain wrong.


More information about the Python-list mailing list