Submission #709797

#TimeUsernameProblemLanguageResultExecution timeMemory
709797raysh07게임 (IOI14_game)C++17
Compilation error
0 ms0 KiB
#include "game.h"
#include "bits/stdc++.h"
using namespace std;

const int N  = 1569; 
int edges[N];
int n;

void initialize(int nn){
    n = nn;
}

int hasEdge(int u, int v){
    if (u>v) swap(u, v);  
    edges[u]++;
    
    return cnt[u] == (n - u);
}

Compilation message (stderr)

game.cpp: In function 'int hasEdge(int, int)':
game.cpp:17:12: error: 'cnt' was not declared in this scope; did you mean 'int'?
   17 |     return cnt[u] == (n - u);
      |            ^~~
      |            int