stdout-a pointer to a FILE structure that means a standard output stream

stdout is a pointer to a FILE structure that means a standard output stream. The standard output stream is automatically opened at the start of the program. A standard output stream generally means output to the screen. You can use it by reading the stdio.h header.

#include <stdio.h>

stdout

stdout is implemented as an expression in the C language specification. stdout can be implemented as a global variable or a macro.

Sample using stdout

This is a sample using stdout. The fprintf function specifies the standard output as the output destination.

#include <stdio.h>

int main (void) {
  const char * message = "Hello";
  fprintf (stdout, "%s\n", message);
}

This is the execution result. "Hello" is displayed on the screen.

Hello

Associated Information