/* character counter */ #include<stdio.h> int main() { short int nc; for(nc=0; getchar()!=EOF ; ++nc); printf("%d\n",nc); return 0; }