putch

Writes a specified character to the current screen

Local Servers:nonblocking
Remote Servers:N/A
Classification:Other
Service:Device I/O

Syntax

  #include <nwconio.h>  
   
  int putch  (  
     int   charToOutput);
  

Parameters

charToOutput

(IN) Specifies the character to be written.

Return Values

If successful, putch returns the character written. If a write error occurs, the error indicator is set and putch returns EOF.

Remarks

The putch function writes the character specified by the charToOutput parameter to the current screen.

putch becomes a blocking function if the character to be written out is the newline character

See Also

getch, getche, ungetch

Example

  #include <stdlib.h>  
  #include <nwconio.h> 
    
  main ()  
  {  
     putch (’a’);  
     putchar (’b’);  
     getch ();  
  }