Submission #1015980

#TimeUsernameProblemLanguageResultExecution timeMemory
1015980SulA마술쇼 (APIO24_show)C++17
Compilation error
0 ms0 KiB
#include <bits/stdc++.h> using namespace std; vector<pair<int, int>> Alice() { long long x = setN(5000); vector<pair<int,int>> tree; for (int i = 1; i <= x; i++) { if (i != x) { tree.push_back({i, x}); } } return tree; }
#include <bits/stdc++.h> using namespace std; long long Bob(vector<pair<int,int>> tree) { int cnt[5001] = {}; for (auto [u,v] : tree) { cnt[u]++, cnt[v]++; } return int(max_element(cnt, cnt+5001) - cnt); }

Compilation message (stderr)

Alice.cpp: In function 'std::vector<std::pair<int, int> > Alice()':
Alice.cpp:5:17: error: 'setN' was not declared in this scope
    5 |   long long x = setN(5000);
      |                 ^~~~