| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 135599 | 李明秦 | 31回文字符串II | C++ | Wrong Answer | 2 MS | 280 KB | 450 | 2025-11-07 18:23:49 |
#include<bits/stdc++.h> using namespace std; string a; bool FUN(int left,int right) { int len=(right-left+1)/2; for(int i=0;i<len;i++){ if(a[left+i]!=a[right-i]){ return false; } return true; } } int main() { cin>>a; int len=a.length(); for(int i=0;i<len-1;i++){ for(int j=len-1;j>i;j--){ if(FUN(i,j)&&(j-i!=1)) { cout<<"Yes"<<endl; return 0; } } } cout<<"No"<<endl; return 0; }
------Input------
qwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwertyuiopasdfghjklzxcvbnmqwerty
------Answer-----
No
------Your output-----
Yes