Advertisement
Guest User

Untitled

a guest
Jan 21st, 2020
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.23 KB | None | 0 0
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5.     int x, y, z, r, t;
  6.     x = 0;
  7.     r = 0;
  8.  
  9.     while((y=getchar()) != EOF){
  10.     if(y == '\n')
  11.         ++z;
  12.     if(y == ' '||y == '\n'||y == '\t')
  13.         ++x;
  14.     else if (x=0)
  15.         ++r;}
  16.     printf("%d%d/n", x,r); 
  17.  
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement