| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 149803 | 王奕杰 | 统计字符数量 | C++ | Time Limit Exceeded | 1000 MS | 264 KB | 492 | 2026-03-16 19:41:15 |
#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ char a[1001],c; cin>>a; int b[27]={},max=0; for(int i=0;a[i]!='\0';i++){ a[i-'a']++; } for(int i=1;a[i]!='\0';){ if(b[a[i]-'a']>max) max=b[a[i]-'a']; } cout<<a<<" "<<max; return 0; }