islice ==> [::]

Raymond Hettinger python at rcn.com
Fri Mar 7 14:55:25 EST 2008


[castiro]
> Slice literals are a logical next step, precedented by raw strings and
> bytes.  slice= islice is too, precedented by range= xrange.

Looking closely at the [::] notation, I think it can easily be
confused with an open box of fleas.  IMO, the one unequivocal,
explicit way of checking for lice is itertools.is_lice().


Raymond

 _ ~
 @ @
 \_/




More information about the Python-list mailing list