0_0_36623495_11091.cpp:16:1: error: missing terminating ' character
bool vis[100'000];
^
0_0_36623495_11091.cpp:24:2: error: missing terminating ' character
return n.x >= 0 && n.x <= 100'000;
^
0_0_36623495_11091.cpp:18:1: error: expected ']' before 'struct'
struct node {
^
0_0_36623495_11091.cpp:23:18: error: 'CHECK' declared as an 'inline' variable
inline int CHECK(node n) {
^
0_0_36623495_11091.cpp:23:18: error: 'node' was not declared in this scope
0_0_36623495_11091.cpp:23:26: error: expected ',' or ';' before '{' token
inline int CHECK(node n) {
^
0_0_36623495_11091.cpp:27:1: error: 'node' does not name a type
node neighbor(node cur, int i) {
^
0_0_36623495_11091.cpp: In function 'void BFS(int, int)':
0_0_36623495_11091.cpp:39:2: error: 'node' was not declared in this scope
node start, next;
^
0_0_36623495_11091.cpp:40:8: error: the value of 'node' is not usable in a constant expression
queue<node> q;
^
0_0_36623495_11091.cpp:39:2: note: 'node' was not declared 'constexpr'
node start, next;
^
0_0_36623495_11091.cpp:40:12: error: type/value mismatch at argument 1 in template parameter list for 'template<class _Tp, class _Sequence> class std::queue'
queue<node> q;
^
0_0_36623495_11091.cpp:40:12: error: expected a type, got 'node'
0_0_36623495_11091.cpp:40:12: error: template argument 2 is invalid
0_0_36623495_11091.cpp:40:15: error: invalid type in declaration before ';' token
queue<node> q;
^
0_0_36623495_11091.cpp:41:4: error: request for member 'push' in 'q', which is of non-class type 'int'
q.push({N,0});
^
0_0_36623495_11091.cpp:42:12: error: request for member 'empty' in 'q', which is of non-class type 'int'
while (!q.empty()) {
^
0_0_36623495_11091.cpp:43:3: error: 'start' was not declared in this scope
start = q.front();
^
0_0_36623495_11091.cpp:43:13: error: request for member 'front' in 'q', which is of non-class type 'int'
start = q.front();
^
0_0_36623495_11091.cpp:46:5: error: request for member 'pop' in 'q', which is of non-class type 'int'
q.pop();
^
0_0_36623495_11091.cpp:48:28: error: 'neighbor' was not declared in this scope
next = neighbor(start, i);
^
0_0_36623495_11091.cpp:49:18: error: 'CHECK' cannot be used as a function
if (CHECK(next) && !vis[next.x]){
^
0_0_36623495_11091.cpp:49:24: error: 'vis' was not declared in this scope
if (CHECK(next) && !vis[next.x]){
^
0_0_36623495_11091.cpp:49:28: error: 'std::next' does not have class type
if (CHECK(next) && !vis[next.x]){
^
0_0_36623495_11091.cpp:50:7: error: request for member 'push' in 'q', which is of non-class type 'int'
q.push(next);
^
0_0_36623495_11091.cpp:51:9: error: 'std::next' does not have class type
vis[next.x] = 1;
^
0_0_36623495_11091.cpp:55:10: error: 'start' was not declared in this scope
cout << start.step << endl;
^
0_0_36623495_11091.cpp: In function 'int main()':
0_0_36623495_11091.cpp:62:10: error: 'vis' was not declared in this scope
memset(vis, 0, sizeof(vis));
^
|