1 solutions
-
0
C++ :
#include<iostream> #include<cstdio> using namespace std; int main() { char c; int letter=0,digit=0,space=0,other=0; while ((c=getchar()) != '\n') if (isalpha(c)) letter++; else if (isalnum(c)) digit++; else if (c==' ') space++; else other++; cout<<letter<<" "<<digit<<" "<<space<<" "<<other<<endl; return 0; }
- 1
Information
- ID
- 19141
- Time
- 1000ms
- Memory
- 128MiB
- Difficulty
- (None)
- Tags
- (None)
- # Submissions
- 0
- Accepted
- 0
- Uploaded By