O(n^2) is bad - can it be fixed?
Bruce Sass
bsass at freenet.edmonton.ab.ca
Fri May 25 14:34:00 EDT 2001
On Fri, 25 May 2001, Tim Peters wrote:
<>
> We can do that if we use our own malloc, but won't otherwise (we're not going
> to add more members to the Python listobject struct, because millions of
> lists with a few things are about a million times more common than a few
> lists with millions of things).
So, the discussion should be about optimizing the existing stuff for
small lists, and creating an extension lib so one can do, maybe...
long_list = []L
or
l = [] ; ... ; l = longlist(l)
?
- Bruce
More information about the Python-list
mailing list