| # | Time | Username | Problem | Language | Result | Execution time | Memory |
|---|---|---|---|---|---|---|---|
| 1366151 | retarde | Game (IOI14_game) | C++20 | 0 ms | 344 KiB |
#include "game.h"
#include <bits/stdc++.h>
using namespace std;
vector<int> cnt;
int lff = 0;
int N = 0;
void initialize(int n) {
N = n;
cnt.assign(N, 0);
lff = 0;
}
int hasEdge(int u, int v) {
if (cnt[u] < cnt[v]) swap(u, v);
cnt[u]++;
cnt[v]++;
if (lff != 2) {
if (cnt[u] == N - 1) {
lff++;
return 1;
}
return 0;
} else {
if (cnt[u] == N - 2) return 1;
return 0;
}
}| # | Result | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Result | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Result | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
