PATCH: Augmented assignment

Moshe Zadka moshez at math.huji.ac.il
Sat Jun 10 18:09:08 EDT 2000


[Moshe Zadka] 
> Anyone doing *that* isn't  familiar with the pydiom:
> 
> s, i = nested_strucre[some_index], another_index
> s[i] = s[i] + 1

[Doug Stanfield]
> Wow, I like that.  Its great!!!
> 
> Could you pass on the link to that storehouse of great pydioms.
> I'd like to see more  ;-Q

Hmmmm....just read a lot of Python source code <wink>
Seriously, though, I learned a lot of Python from the standard library, 
and the Demo/ and Tools/ directories of the source distribution.
--
Moshe Zadka <moshez at math.huji.ac.il>
http://www.oreilly.com/news/prescod_0300.html
http://www.linux.org.il -- we put the penguin in .com





More information about the Python-list mailing list