Q:

How to find End of File in Python

In python I am facing a strange situation - I am reading it character by charecter and can not determine the End of File. Can you please help me out?

A:

The end of a file is indicated when the read() returns less data than you asked for.

