home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / unix / volume15 / yp-quote / addpct.c next >
Encoding:
C/C++ Source or Header  |  1988-06-07  |  356 b   |  21 lines

  1. /*
  2.  * This takes a file with quotes delimited by a blank line (typically
  3.  * a moriarty quote file) and turns it into a %% delimited file that
  4.  * can be imported into a fortune database
  5.  *
  6.  * chuq von rospach
  7.  */
  8.  
  9. #include <stdio.h>
  10.  
  11. main()
  12. {
  13.     char line[BUFSIZ];
  14.  
  15.     while (gets(line))
  16.     if (strlen(line))
  17.         puts(line);
  18.     else
  19.         printf("%%%%\n");
  20. }
  21.