Run ID Author Problem Lang Verdict Time Memory Code Length Submit Time
44240 奚晨瑞 判断字符串是否为回文 C++ Accepted 1 MS 244 KB 285 2024-03-29 15:43:47

Tests(4/4):


#include<iostream> #include<cstring> using namespace std; char a[101]; int main() { cin>>a; int b=strlen(a); bool t=0; for(int i=0;2*i<b-1;i++){ if(a[i]!=a[b-1-i]){ t=1; break; } } if(t==0){ cout<<"yes"; } else{ cout<<"no"; } return 0; }


Judgement Protocol: