Programmer's Wiki
Advertisement

Synopsis[]

#include <stdio.h>
int puts(const char *s);

Description[]

puts writes the string pointed to by s to stdout and appends a '\n' (linefeed).

It returns EOF on error.

Examples[]

#include <stdio.h>

int main()
{
  puts("Hello, World!");

  return 0;
}

This will simply print "Hello, World!", followed by line feed, to stdout.

See also[]

Advertisement