[Previous]
[Contents]
[Next]

putch()

write a character to the console

Synopsis:

#include <conio.h>
int putch( int c );

Description:

The putch() function writes the character specified by the argument c to the console.

Returns:

The character written.

Examples:

#include <conio.h>
#include <stdio.h>

void main()
  {
    FILE *fp;
    int c;

    fp = fopen( "file", "r" );
    if ( fp != NULL ) {
      while( (c = fgetc( fp )) != EOF )
        putch( c );
    }
    fclose( fp );
  }

Classification:

WATCOM

Safety:
Interrupt handler No
Signal handler No
Thread Yes

See also:

errno, getch(), getche(), kbhit(), ungetch()


[Previous]
[Contents]
[Next]