Run ID Author Problem Lang Verdict Time Memory Code Length Submit Time
44262 王shizhao 判断字符串是否为回文 C++ Accepted 1 MS 260 KB 393 2024-03-29 15:59:00

Tests(4/4):


#include<iostream> #include<cstdio> #include<cstring> using namespace std; int main() { char s[100]; int len,position; 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; }


Judgement Protocol: