Run ID Author Problem Lang Verdict Time Memory Code Length Submit Time
44643 zhangchunhong 判断字符串是否为回文 C++ Accepted 0 MS 248 KB 251 2024-03-31 18:14:04

Tests(4/4):


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


Judgement Protocol: