range(seq)?

Jeff Shannon jeff at ccvcorp.com
Fri Feb 8 15:30:24 EST 2002


Magnus Lie Hetland wrote:

>   for x in range(seq): ...
>
> I.e. let range() take a sequence (or iterable) as an argument, and
> generate range(len(seq)).

This seems more logical and intuitive to me, than the previous
suggestions.

Whether that's enough to justify its being added to Python is another
question entirely, of course.  ;)

Jeff Shannon
Technician/Programmer
Credit International





More information about the Python-list mailing list