fastest table lookup

Scott David Daniels Scott.Daniels at Acm.Org
Mon Oct 25 15:57:48 EDT 2004


Jeff Shannon wrote:
> ... IIRC, list (and tuple) indexing is  O(n) (with n=len(list)), ...
Nope, that may be LISPish knowledge or some other linked list
implementation.
Python's tuple, list, and array (and Numeric array) indexing is O(1).

-Scott David Daniels
Scott.Daniels at Acm.Org



More information about the Python-list mailing list