 
      
      file::eof()Check whether file pointer is at the end-of-file (EOF) or not
file::eof()There are no parameters.
boolean — Returns true if file pointer is at EOF, and returns false if otherwise
import fileio
 
f = file("data.txt", file_read)
 
while !f.eof()
    line = f.readln()
endwhile
 
f.close()