Recursively traverse linked list -- help!
Gustavo Niemeyer
niemeyer at conectiva.com
Wed Feb 20 08:58:07 EST 2002
> Well actually it is fair, because the insertion time for the linked list
> is constant, as long as you have a handle to the insertion point. That's
That indeed would be true if you always have a handle to the insertion
point. But 136500% of overhead in the usual case is too much for me.
> pretty much the reason for using it. Inserting at the start will be just
> as fast/slow as inserting in the middle. I just didn't feel like
> rewriting the class so that it would take an arbitrary insertion point.
That's the "point". It's not an arbitrary insertion point at all. It's a
point where you have the handle.
--
Gustavo Niemeyer
[ 2AAC 7928 0FBF 0299 5EB5 60E2 2253 B29A 6664 3A0C ]
More information about the Python-list
mailing list