Reading a file

Tim Northover tim at pnorthover.freeserve.co.uk
Tue Jul 25 15:27:42 EDT 2000


I'm attempting to read a file line by line with readline(), but it
seems to return and empty string when EOF is encountered. Is there a
way of discerning the difference between the end of the file and a
blank line in the file?

I'm very new to this so I don't know the methods used but I couldn't
find anything relevant when grepping the html docs.

Tim N.



More information about the Python-list mailing list