Why is my code faster with append() in a loop than with a large list?
Piet van Oostrum
piet at cs.uu.nl
Mon Jul 6 18:51:24 EDT 2009
>>>>> Scott David Daniels <Scott.Daniels at Acm.Org> (SDD) wrote:
>SDD> # No need for global declarations, we alter, not replace
Yes, I know, but I find it neater to do the global declarations, if only
for documentation. And they don't affect the run time, only the compile
time.
--
Piet van Oostrum <piet at cs.uu.nl>
URL: http://pietvanoostrum.com [PGP 8DAE142BE17999C4]
Private email: piet at vanoostrum.org
More information about the Python-list
mailing list