daily pastebin goal
23%
SHARE
TWEET

Untitled

a guest Mar 13th, 2018 53 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <stdio.h>
  2.  
  3. #define TRUE 1
  4. #define FALSE 0
  5.  
  6. main()
  7. {
  8.  
  9.     int c;
  10.     int blanks = FALSE;
  11.  
  12.     while ((c = getchar()) != EOF){
  13.  
  14.         if (c != ' '){
  15.             blanks = FALSE;
  16.             putchar(c);
  17.         }
  18.         else
  19.             if ((c == ' ') && (blanks == FALSE)){
  20.                 blanks = TRUE;
  21.                 putchar(c);
  22.             }
  23.     }
  24. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top