rewind

Full prototype:

void rewind(FILE*);  

Purpose and Notes:

Sets the current file position for the file associated with the FILE* passed in as the first and only argument to the function to the beggining of the file and also clears any error indicators for the stream.

It is equivalent to using:
fseek(FILE*, 0, SEEK_SET);

clearerr(FILE*);

Where "FILE*" is the FILE* of the stream you want to reset error indicators and go to the beginning of.

Returns:

void-No value is returned.

Argument 1:

FILE*-A file pointer associated with the stream you want to go back to the beginning of and clear error indicators.

Example 1
  1    FILLER SOURCE CODE
FILLER TERMINAL