loop iterators?

SpreadTooThin bjobrien62 at gmail.com
Tue Oct 17 13:01:51 EDT 2006


Hi I need to get a for loop to give me an element from a list and an
index number...
for example:

i = 0
l = ['a','b','c']
for e in l:
   print l, i
   i = i + 1

Is there a way to get rid of the i processing in this script?
Sorry I'm still trying to learn python tricks here...




More information about the Python-list mailing list