Nikhil <[EMAIL PROTECTED]> writes: > Arnaud Delobelle wrote: > >> The standard Python way is using enumerate() >> >> for i, line in enumerate(fp): >> print "line number: " + lineno + ": " + line.rstrip() >> > > I guess you meant to say : > > for lineno, line in enumerate(fp): > print "line number: " + lineno + ": " + line.rstrip()
Yes! -- Arnaud -- http://mail.python.org/mailman/listinfo/python-list