| # | Time | Username | Problem | Language | Result | Execution time | Memory |
|---|---|---|---|---|---|---|---|
| 1366960 | farica | Chameleon's Love (JOI20_chameleon) | C++20 | 17 ms | 428 KiB |
#include "chameleon.h"
#include <cstdio>
#include <cstdlib>
#include <bits/stdc++.h>
using namespace std;
using vi = vector<int>;
int Query(const std::vector<int> &p);
void Answer(int a, int b);
void Solve(int N) {
vector<bool>fnd(2*N+1, 0);
for(int i=1; i<=2*N; ++i) {
if(fnd[i]) continue;
for(int j=i+1; j<=2*N; ++j) {
if(fnd[j]) continue;
vi p;
p.push_back(i); p.push_back(j);
int res = Query(p);
if(res == 1) {
Answer(i, j);
fnd[i] = fnd[j] = 1;
break;
}
}
}
}| # | Result | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Result | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Result | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Result | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Result | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
