#include<stdio.h> int main() { int n=0; char str[100]; while(scanf("%s",str)!=EOF) { n++; } printf("%d",n); }
Double click to view unformatted code.