Run ID 作者 问题 语言 测评结果 时间 内存 代码长度 提交时间
39656 奚晨瑞 验证子串 C++ 解答错误 1 MS 256 KB 369 2024-02-03 18:12:37

Tests(1/3):


#include<iostream> #include<cstring> using namespace std; int main() { string s1; string s2; cin>>s1>>s2; if(s2.find(s1) != string::npos) { cout << s1 << "is substring of" << s2 << endl; } else if(s1.find(s2) != string::npos) { cout << s2 << "is substring of" << s1 << endl; } else { cout << "No substring" << endl; } return 0; }


测评信息: