grante at visi.com
Thu Dec 23 17:28:50 CET 2004
On 2004-12-23, Steven Bethard <steven.bethard at gmail.com> wrote:
>> Ah, my mistake, I missed the [:] after the source argument
>> that was taking a copy... which brings up the question, how
>> many other people would miss it?
> Too many. This is why I greatly prefer
To me, that's just as non-obvious. I would have guessed that
calling list() on a list was a noop. I would be wrong.
Surprised, but wrong.
> It's also clearer to me. Do I really want a "slice" of the
> list? No, I want a list copy of the list...
Wouldn't the clearest way to get a copy would be to do
copy(lst) # I still think copy.copy() is a bit verbose...
lst.copy() # doesn't exist, but I think it should :)
Grant Edwards grante Yow! I had pancake makeup
at for brunch!
More information about the Python-list