tj
2024-10-13 16:56:03
发布于:上海
0阅读
0回复
0点赞
#include<bits/stdc++.h>
using namespace std;
int main(){
string s1,s2;
cin>>s1;
cin>>s2;
if(s1.find(s2)!=string::npos) cout<<s2<<" is substring of "<<s1;
else if(s2.find(s1)!=string::npos) cout<<s1<<" is substring of "<<s2;
else cout<<"No substring";
return 0;
}
这里空空如也
有帮助,赞一个