解析
字符串的操作
#include <bits/stdc++.h>
using namespace std;
int f = 0;
string a, b;
int main()
{
cin >> a >> b;
for (int i = 0; i < a.size (); ++ i)
{
char c = a[0];
a = a.substr (1, a.size() - 1);
a = a + c;
if (a.find (b, 0) != string::npos)
{
cout << "true";
f = 1;
break;
}
}
if (!f) cout << "false";
return 0;
}