提交时间:2024-02-18 16:21:07

运行 ID: 41019

#include<bits/stdc++.h> using namespace std; int main(){ char y[1005]; int cnt=0; gets(y); for(int i=0;i<strlen(y);i++){ if(y[i]>='A'&&y[i]<='Z')y[i]+=32; } string y2=y; for(int i=0;i<strlen(y)-7;i++){ if(y2.substr(i,7)=="lanqiao")cnt++; } cout<<cnt; return 0; }