Sorted dictionary

Daniel Stutzbach daniel at stutzbachenterprises.com
Thu Jan 21 14:35:55 EST 2010


On Thu, Jan 21, 2010 at 12:45 PM, Jan Kaliszewski <zuo at chopin.edu.pl> wrote:

> Please note that I used funcions from bisect, that use binary search.
>
> Doesn't it take O(log n) time?
>

It takes O(log n) time to find the point to insert, but O(n) time to perform
the actual insertion.

--
Daniel Stutzbach, Ph.D.
President, Stutzbach Enterprises, LLC <http://stutzbachenterprises.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20100121/bfe4ab06/attachment-0001.html>


More information about the Python-list mailing list