Performance: sets vs dicts.
john at castleamber.com
Thu Sep 2 02:11:03 CEST 2010
Terry Reedy <tjreedy at udel.edu> writes:
> On 9/1/2010 5:40 PM, John Bokma wrote:
> Yes, I switched, because 'constant time' is a comprehensible claim
> that can be refuted and because that is how some will interpret O(1)
> (see below for proof;-).
You make it now sound alsof this interpretation is not correct or out of
place. People who have bothered to read ItA will use O(1) and constant
time interchangeably while talking of the order of growth of the running
time algorithms and most of those are aware that 'big oh' hides a
constant, and that in the real world a O(log n) algorithm can outperform
an O(1) algorithm for small values of n.
>> Uhm, O(1) /is/ constant time, see page 45 of Introduction to Algorithms,
>> 2nd edition.
John Bokma j3b
Blog: http://johnbokma.com/ Facebook: http://www.facebook.com/j.j.j.bokma
Freelance Perl & Python Development: http://castleamber.com/
More information about the Python-list