home *** CD-ROM | disk | FTP | other *** search
/ gondwana.ecr.mu.oz.au/pub/ / Graphics.tar / Graphics / VOGLE.ZIP / SRC / MSFORT / ZAP_C.C < prev   
C/C++ Source or Header  |  2000-02-11  |  378b  |  27 lines

  1. #include <stdio.h>
  2.  
  3. main()
  4. {
  5.     int    c1, c2, c3;
  6.  
  7.     while ((c1 = getchar()) != EOF) {
  8.         if (c1 == '_') {
  9.             if ((c2 = getchar()) == 'c') {
  10.                 if ((c3 = getchar()) == '_') {
  11.                     putchar(c3);
  12.                 } else {
  13.                     putchar(c1);
  14.                     putchar(c2);
  15.                     putchar(c3);
  16.                 }
  17.             } else {
  18.                 putchar(c1);
  19.                 putchar(c2);
  20.             }
  21.         } else {
  22.             putchar(c1);
  23.         }
  24.     }
  25. }
  26.             
  27.