Previous | Home | Next |
Description
The C library function, The puts( ) function writes the string pointed to by str to the standard output device. The function begins copying from the address specified (str) until it reaches the terminating null character ('\0'). This terminating null-character is not copied to the stream.
Declaration
Following is the declaration for puts() function.
int puts(const char *str)
Parameters
str - The string to write to stdout.
Return Value
The puts( ) function returns a nonnegative value if successful and an EOF upon failure.
Example
#include <stdio.h> int main () { char string [] = "Hello!"; puts (string); }
Previous | Home | Next |