| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 136444 | 李朋秦 | 统计特定单词数 | C++ | Wrong Answer | 1 MS | 276 KB | 370 | 2025-11-14 16:49:52 |
#include<bits/stdc++.h> using namespace std; int main() { string a,b; getline(cin,a); getline(cin,b); int l1=a.size(),l2=b.size(),g=0,y=0,c=0; for(int i=0;i<l2;i++)b[i]=toupper(b[i]); for(int i=0;i<l1;i++)a[i]=toupper(a[i]); y=b.find(a); for(int i=0;i<l2;i++){ c=b.find(a); if(c!=-1)g++; b.erase(c+1,l1); }cout<<g<<" "<<y; return 0; }
------Input------
alun Alunis the best teacher of TCJY alun
------Answer-----
1 32
------Your output-----
2 0