home *** CD-ROM | disk | FTP | other *** search
/ World of A1200 / World_Of_A1200.iso / datafiles / text / c_tutor / singleio.c < prev    next >
C/C++ Source or Header  |  1995-02-27  |  292b  |  16 lines

  1. #include "stdio.h"
  2.  
  3. main()
  4. {
  5. char c;
  6.  
  7.    printf("Enter any characters, terminate program with X\n");
  8.  
  9.    do {
  10.       c = getch();                     /* get a character */
  11.       putchar(c);                  /* display the hit key */
  12.    } while (c != 'X');
  13.  
  14.    printf("\nEnd of program.\n");
  15. }
  16.