[triangle-zpug] why is this using a lot of memory?
david at handysoftware.com
Tue Mar 25 15:48:29 UTC 2008
On Tue, Mar 25, 2008 at 08:23:56AM -0700, Joseph Mack NA3T wrote:
> intervals=10000000 #some large number
> for x in range(0, intervals):
range() constructs a list in memory, populating the entire thing with each
Try xrange() instead, that's what you want.
Computer Programming is Fun!
Beginning Computer Programming with Python
More information about the triangle-zpug