Submission #49348

#TimeUsernameProblemLanguageResultExecution timeMemory
49348MoNsTeR_CuBeGame (IOI14_game)C++17
Compilation error
0 ms0 KiB
#include "game.h" #include <bits/stdc++.h> vector<int> ans(0); void initialize(int n) { ans.resize(n); ans[0] = 1; ans[1] = 0; ans[2] = 0; ans[3] = 0; ans[4] = 1; ans[5] = 1; } int counter = 0; int hasEdge(int u, int v) { counter++; return ans[counter-1]; }

Compilation message (stderr)

game.cpp:3:1: error: 'vector' does not name a type; did you mean 'wctob'?
 vector<int> ans(0);
 ^~~~~~
 wctob
game.cpp: In function 'void initialize(int)':
game.cpp:6:2: error: 'ans' was not declared in this scope
  ans.resize(n);
  ^~~
game.cpp:6:2: note: suggested alternative: 'abs'
  ans.resize(n);
  ^~~
  abs
game.cpp: In function 'int hasEdge(int, int)':
game.cpp:19:12: error: 'ans' was not declared in this scope
     return ans[counter-1];
            ^~~
game.cpp:19:12: note: suggested alternative: 'abs'
     return ans[counter-1];
            ^~~
            abs