Adding item in front of a list

Alex Martelli aleax at aleax.it
Sat Apr 12 13:19:53 EDT 2003


Tim Peters wrote:
   ...
> reverted).  Saving you from needing to type 0 when you mean 0 doesn't
> outweigh the ugliness of making the first argument mean different things
> depending on how many arguments there are.

Are we talking about the same language, Tim?  I.e., Python, where
range(7) and range(0,7) are synonyms...?  Why can't mylist.insert
use just the same "first argument means different things" convention
as range...?

I'm not necessarily arguing for this, but given the looming precedent
of range and xrange I do find your motivation confusing...


Alex





More information about the Python-list mailing list