分别统计其中大写字母小写字母及其它字符的个数?
#include<iostream>
using namespace std;
void main(){
char input[1000];
int i=0,out[26]={0},j;
char outstring[26]=
{'A','B','C','D','E','F','G','H','I','J','K','L',
'M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z'};
cout<<"Please
input capital password:";
fgets(input,1000,stdin);
while(input<i>){
if(input<i>>=
'A'&&input<i><='Z'){
out[input<i>-'A']++;
}
i++;
}
cout<<"输出:"<<endl;
for(j=0;j<26;j++){
cout<<outstring[j]<<
":"<<out[j]<<endl;
}