home *** CD-ROM | disk | FTP | other *** search
/ Frozen Fish 1: Amiga / FrozenFish-Apr94.iso / bbs / alib / d9xx / d958 / fed-case.lha / Fed-CASE / sources / wcount.c < prev    next >
C/C++ Source or Header  |  1993-12-04  |  3KB  |  69 lines

  1. /************************************************************************/
  2. /*                                                                      */
  3. /*         Code generated by FED-CASE V1.0  Code Generator              */
  4. /*                  © Joosen Software Development                       */
  5. /*                    All rights reserved 1993                          */
  6. /*                                                                      */
  7. /************************************************************************/
  8.  
  9. /************************************************************************/
  10. /*                                                                      */
  11. /*                          Start of Includes                           */
  12. /*                                                                      */
  13. /************************************************************************/
  14.  
  15. #include <exec/types.h>
  16. #include <data/const_wcount.h>
  17. #include <stdio.h>
  18.  
  19. /************************************************************************/
  20. /*                                                                      */
  21. /*                           End of Includes                            */
  22. /*                                                                      */
  23. /************************************************************************/
  24.  
  25. /************************************************************************/
  26. /*                                                                      */
  27. /*                    Start of source prototype file                    */
  28. /*                                                                      */
  29. /************************************************************************/
  30.  
  31. #include <proto/proto_wcount.h>
  32.  
  33. /************************************************************************/
  34. /*                                                                      */
  35. /*                     End of source prototype file                     */
  36. /*                                                                      */
  37. /************************************************************************/
  38.  
  39.  
  40. /************************************************************************/
  41. /* Procedure  : void main()                                             */
  42. /* Function   :                                                         */
  43. /* Designer   : Ron Heijmans                                            */
  44. /* Date       : Sat Nov 27 13:55:06 1993                                */
  45. /*                                                                      */
  46. /* Modificat  :                                                         */
  47. /* Handler    :                                                         */
  48. /* Modific.   :                                                         */
  49. /*                                                                      */
  50. /************************************************************************/
  51.  
  52. void main()
  53. {
  54. int LI_tel;
  55. char LC_ch;
  56.  
  57.     LC_ch= (char)getchar() ;                /* getchar: Read one character  */
  58.     LI_tel= 0;
  59.     while(    LC_ch!= EOF)                    /* EOF: */
  60.     {
  61.         if (LC_ch== ' ' )
  62.         {
  63.             LI_tel++;
  64.         }                        /* end of 'if(LC_ch == ' ')' */
  65.         LC_ch= (char)getchar();                /* getchar: Read one character  */
  66.     }                            /* end of while(LC_ch!=EOF) */
  67.     printf( "number of words : %d\n" , LI_tel );        /* printf: Standard output function */
  68. }                                /* end of V_main */
  69.