T napisaĆ(a): > Do I need to close the file in this case? Why or why not? > > for line in file('foo', 'r'): > print line
No, if you only read from the file. But anyway, closing file object is considered good practice in many documents I found, no matter what you do with it. -- Jarek Zgoda http://jpa.berlios.de/ -- http://mail.python.org/mailman/listinfo/python-list