Gets the next character from a stream.
#include <stdio.h> int getc ( FILE *fp);
(IN) Points to the file.
If successful, returns the next byte from the input stream. Otherwise, if the stream is at end-of-file, returns EOF and sets the EOF indicator. If a read error occurs, returns EOF, sets the error indicator, and sets errno to one of the following:
The getc function or macro gets the next character from the file designated by fp. The character is returned as an int value.
The getc function is equivalent to fgetc, except that it can be implemented as a macro.