EOF" -- Manifest Constant" "

Indicate end of a file

#include <stdio.h>

EOF is an indicator that is returned by several STDIO functions to indicate that the current file position is the end of the file.

Many STDIO functions, when they read EOF, set the end-of-file indicator that is associated with the stream being read. Before more data can be read from the stream, its end-of-file indicator must be cleared. Resetting the file-position indicator with the functions fseek, fsetpos, or ftell will clear the indicator, as will returning a character to the stream with the function ungetc.

See Also