#include <stdio.h> char *gets(char *buffer);
Reads characters from stdin
, storing them in buffer, until
either end of file or a newline is encountered. If any characters were
stored, the buffer is then NULL
terminated and its address
is returned, else NULL
is returned.
The address of the buffer, or NULL
.
ANSI, POSIX
char buf[1000]; while (gets(buf)) puts(buf);
Go to the first, previous, next, last section, table of contents.