On 7/30/07, Greg Ewing <[EMAIL PROTECTED]> wrote: > The sort of thing I have in mind is where I have a sequence > that I want to frequently iterate over the indices of, so > I do > > r = xrange(len(myseq)) > > so I can write > > for i in r: > ... > > Having done that, if I want to test whether some index j > is within the range of indices for this sequence, it > seems natural to write > > if j in r: > ... > > Given the context, I think this is a very Obvious Way To > Do It, and it's surprising that it isn't as efficient as it > looks like it should be.
Fair enough. So maybe *you* can contribute a patch? -- --Guido van Rossum (home page: http://www.python.org/~guido/) _______________________________________________ Python-3000 mailing list [email protected] http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com
