C Language: fputs function
(Write String from File)
In the C Programming Language, the fputs function writes a string to the stream pointed to by stream.
Syntax
The syntax for the fputs function in the C Language is:
int fputs(const char *s, FILE *stream);
Parameters or Arguments
- s
- The string to write to the stream.
- stream
- The stream to write to.
Returns
The fputs function a nonnegative value if it is successful. The fputs function will return an EOF if an error occurs while trying to write to the stream.
Required Header
In the C Language, the required header for the fputs function is:
#include <stdio.h>
Applies To
In the C Language, the fputs function can be used in the following versions:
- ANSI/ISO 9899-1990
Similar Functions
Other C functions that are similar to the fputs function:
See Also
Other C functions that are noteworthy when dealing with the fputs function:
Advertisements