QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#449498 | #8583. 팰린드롬 판별하기 | thangthang | Compile Error | / | / | C++20 | 683b | 2024-06-21 12:28:31 | 2024-06-21 12:28:33 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
int guess_palindromicity(int n){
vector <int> n1, n2;
for (int i = 1; i <= (n - 1) / 2; ++ i){
int gg = count_pair(0, i, n - 1 - i);
if (!gg) return 0;
if (gg == 1) n1.push_back(i);
else n2.push_back(i);
}
if (find_character(0, n1)) return 0;
if (n2.size()){
int i = n2.back();
if (count_pair(n - 1, n - 1 - i, i) == 1) return 0;
return 1;
}
int i = n1.back();
int gg = cout_pair(0, n - 1, i);
if (!gg) return 0;
if (gg == 3) return 1;
if (count_pair(n - 1, i, n - i - 1) == 3) return 0;
return 1;
}
詳細信息
answer.code: In function ‘int guess_palindromicity(int)’: answer.code:9:18: error: ‘count_pair’ was not declared in this scope 9 | int gg = count_pair(0, i, n - 1 - i); | ^~~~~~~~~~ answer.code:15:9: error: ‘find_character’ was not declared in this scope 15 | if (find_character(0, n1)) return 0; | ^~~~~~~~~~~~~~ answer.code:19:13: error: ‘count_pair’ was not declared in this scope 19 | if (count_pair(n - 1, n - 1 - i, i) == 1) return 0; | ^~~~~~~~~~ answer.code:23:14: error: ‘cout_pair’ was not declared in this scope 23 | int gg = cout_pair(0, n - 1, i); | ^~~~~~~~~ answer.code:26:9: error: ‘count_pair’ was not declared in this scope 26 | if (count_pair(n - 1, i, n - i - 1) == 3) return 0; | ^~~~~~~~~~