[Python-talk] {Python-talk] Running off the end of a file during read?

Kent Johnson kent37 at tds.net
Sun Jun 14 13:23:34 EDT 2009


On Sun, Jun 14, 2009 at 12:24 PM, Bruce
Labitt<bruce.labitt at myfairpoint.net> wrote:
> Does f.read(n) error if the function hits eof?  If not how can I determine
> when I hit eof?

IIUC read(n) returns <n bytes if it hits EOF.

Kent


More information about the Python-talk mailing list