| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 81695 | 石晋骁 | 回文字符串I | C++ | Compile Error | 0 MS | 0 KB | 231 | 2024-07-12 15:09:30 |
#include<bits/stdc++.h> using namespace std; int main(){ char a[1001]; cin >> a; for(int i =1;i <= a[strlen];i++){ if(a[i] != a[strlen(a)-i-1]){ cout << "No"; return 0; } } cout << "Yes"; return 0; }
Main.cc: In function 'int main()':
Main.cc:6:28: error: invalid types 'char [1001][size_t(const char*) throw () {aka long unsigned int(const char*) throw ()}]' for array subscript
for(int i =1;i <= a[strlen];i++){
^