提交时间:2024-01-19 15:19:01

运行 ID: 37141

#include<iostream> #include<string> #include<cstring> using namespace std; int main() { char s[100]; int len; int i,j; gets(s); len=strlen(s); i=0; j=len-1; while(i<j&&s[i]==s[j]){ i++; j--; } if(i>=j){ cout<<"yes"<<endl; } else cout<<"no"<<endl; return 0; }