| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 164200 | 刘杨国卿 | 统计字符数量 | C++ | Accepted | 1 MS | 276 KB | 299 | 2026-11-01 11:33:49 |
#include<bits/stdc++.h> using namespace std; int a[26]; int main() { string s; cin>>s; for(int i=0;s[i]!='\0';i++){ int m=s[i]-97; a[m]++; } int max=0,n; for(int i=0;i<=25;i++){ if(a[i]>max){ n=i; max=a[i];//g } } cout<<char(n+97)<<" "<<max; return 0; }