Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
132508 郝王骏程 31回文字符串 C++ Compile Error 0 MS 0 KB 471 2025-10-08 19:00:10

Tests(0/0):


Code:

#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int a; string s; cin>>s; a=s.size( ); for(int=a/2;i>=0;i-- ){ if(s[i]!=s[a-i-1]){ cout<<"No"; return 0; } } cout<<"Yes"; return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:12:12: error: expected unqualified-id before '=' token
     for(int=a/2;i>=0;i-- ){
            ^
Main.cc:12:12: error: expected ';' before '=' token
Main.cc:12:12: error: expected primary-expression before '=' token
Main.cc:12:17: error: 'i' was not declared in this scope
     for(int=a/2;i>=0;i-- ){
                 ^
Main.cc:12:21: error: expected ')' before ';' token
     for(int=a/2;i>=0;i-- ){
                     ^
Main.cc:12:22: error: 'i' was not declared in this scope
     for(int=a/2;i>=0;i-- ){
                      ^