www.delorie.com/djgpp/doc/libc-2.01/libc_666.html   search  
Go to the first, previous, next, last section, table of contents.


ungetc

Syntax

#include <stdio.h>

int ungetc(int c, FILE *file);

Description

This function pushes c back into the file. You can only push back one character at a time.

Return Value

The pushed-back character, or EOF on error.

Example

int q;
while (q = getc(stdin) != 'q');
ungetc(q);


Go to the first, previous, next, last section, table of contents.

  prev next   webmaster     delorie software   privacy  
  Copyright © 1997     Updated Apr 1997