> Hi, I'm a newbie to Python and I would like to know if someone can explain > to me why the following script starts using in excess of 80Mb of memory, > when the for loop is running: > > import sys > import time > > start=time.time() > for i in range(0,9999999) : Python actually creates a list of that many integers!! See the xrange() function for a more memory efficient technique. Mark. _______________________________________________ ActivePython mailing list [EMAIL PROTECTED] http://listserv.ActiveState.com/mailman/listinfo/activepython
