Range Operation pre-PEP

Terry Reedy reedy37 at home.com
Wed May 9 12:01:13 EDT 2001


"Thomas Heller" <thomas.heller at ion-tof.com> wrote in message
news:9dbj8j$h83n5$1 at ID-59885.news.dfncis.de...
> > > Ok, I'm in brainstorm mode. You're warned :-) Some weird ideas are
just
> > > popping out of my mind:
> > >
> for i in [0:10):
>     print i
>
> for i in [0:10]:
>     print i

Since this is standard math notation for ranges, with : substituted for ,
to avoid syntax conflict, I like it the best of all proposals in this
thread.  A step value, is present, could go either in middle or end.






More information about the Python-list mailing list