Memory Hungry in Windows
Geiger Ho
s997659 at ee.cuhk.edu.hk
Thu Nov 27 01:00:27 EST 2003
Hi,
I have a program. It opens a text file about 2 MB. It reads in every
line and appends them to a string. It then does a re.sub() to replace the
contents of the long string and then write to a file.
In Linux, it consumes about 5 MB, but in W2k, it concumes 20 MB! Why
there is so much difference for the same piece of code? This has
frightened me that I don't know if the program will crash for no memeory
available somedays.
Thanks in advance.
Regards,
Geiger
# Very Interesting Question:
# id(a) == id(b) and a is not b --> bug?
# from comp.lang.python
More information about the Python-list
mailing list