puts
Writes a specified character string to the output stream and appends a newline character to the output
#include <stdio.h>
int puts (
const char *buf);
The puts function returns a nonzero value if an error occurs; otherwise, it returns a value of 0. If an error occurs, errno is set.
The puts function writes the character string pointed to by buf to the output stream designated by stdout and appends a newline character to the output. The terminating NULL character is not written.
#include <stdio.h>
main ()
{
FILE *fp;
char buffer[80];
fp = freopen ("data.fil", "r", stdin);
while (gets (buffer) != NULL)
puts (buffer);
fclose (fp);
}