In article <878w3ogpvq....@benfinney.id.au>, Ben Finney <ben+pyt...@benfinney.id.au> wrote: >a...@pythoncraft.com (Aahz) writes: >> >> That reminds me: one co-worker (who really should have known better ;-) >> had the impression that sets were O(N) rather than O(1). > >For settling exactly this kind of confusion, Python's standard library >comes with a module, the timeit module. Your co-worker should have >known better: don't guess about timing performance, measure it. > >Or am I missing something here?
Possibly; IMO, people should not need to run timeit to determine basic algorithmic speed for standard Python datatypes. -- Aahz (a...@pythoncraft.com) <*> http://www.pythoncraft.com/ "...if I were on life-support, I'd rather have it run by a Gameboy than a Windows box." --Cliff Wells -- http://mail.python.org/mailman/listinfo/python-list