Character Input/Output Functions

Top  Previous  Next

fgetc

returns the next character from a file; generates a true function call


fgets

reads a line from a file; the line is terminated by a NUL character


fputc

writes a single character to a file; generates a true function call


fputs

writes a string to a file


getc

returns the next character from a file; implemented as a macro


getchar

returns the next character from standard input


gets

reads a line from standard input; replacing the newline with a NUL character


putc

writes a single character to a file; implemented as a macro


putchar

writes a single character to standard output


puts

writes a string to standard output; terminates the string with a newline


ungetc

writes a character to a file buffer leaving the file positioned before the character