(ANSI Standard)
#include <stdio.h> ptr = gets( s );
"gets" reads a string into memory and returns a pointer to this string. Collection of the string begins at the current point in the input stream and ends when a new-line character is encountered (or end-of-file). The new-line is replaced by a '\0' as the string is copied into "s".
If there is a read error or you have reached end of file, "gets" returns NULL.
Copyright © 1996, Thinkage Ltd.