fputc

Syntax

int fputc(int c, int * fileptr)

Arguments

c
An integer containing a byte value.
fileptr
Pointer to a file opened using fopen.

Return

The value of c if succesful, otherwise -1.

Description

Write a single byte, contained in variable c to the file referenced by fileptr.

Also see

fopen, fgetc, putc, fputs

Comments

Everyone can add his comments about his experiences with this function here. Tips for using it are welcome, too.