*Naming Conventions*

Carsten Haese carsten at uniqsys.com
Mon Jun 4 17:28:32 EDT 2007


On Mon, 2007-06-04 at 23:20 +0200, Wildemar Wildenburger wrote:
>  I guess it is commonplace to use i, j, k and n 
> (maybe others) in constructs like
> 
> for i in range(len(data)):
>     do_stuff(data[i])
> 
> Or should the good python hacker do that differently? Hope not ;).

That's a big, fat "Heck, Yes":

for thing in data:
   do_stuff(thing)

-- 
Carsten Haese
http://informixdb.sourceforge.net





More information about the Python-list mailing list