Glenn Hutchings wrote:

Have you checked memory usage while your program is running?  Your

    lines = f.readlines()[2:]

statement will need almost twice the memory of your largest file.

footnote: list objects contain references to string objects, not the strings themselves. the above temporarily creates two list objects, but the actual file content is only stored once.

</F>

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to