# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
1051176 | 2024-08-09T22:17:18 Z | Trent | 드문 곤충 (IOI22_insects) | C++17 | 204 ms | 600 KB |
#include "insects.h" #include "bits/stdc++.h" using namespace std; #define forR(i, x) for(int i = 0; i < (x); ++i) #define REP(i, a, b) for(int i = (a); i < (b); ++i) #define all(x) x.begin(), x.end() typedef long long ll; typedef vector<int> vi; typedef vector<vi> vvi; typedef vector<ll> vll; typedef vector<bool> vb; int min_cardinality(int N) { vvi dst; set<int> vals; forR(i, N) vals.insert(i); while(dst.size() <= 1 || dst[dst.size() - 1].size() == dst[dst.size() - 2].size()) { dst.emplace_back(); for(int i : vals) { move_inside(i); if(press_button() == dst.size()) { dst.back().push_back(i); } else { move_outside(i); } } for(int i : dst.back()) vals.erase(vals.find(i)); } // for(vi& i : dst) { // for(int j : i) cerr << j << ' '; // cerr << '\n'; // } return dst.size() - 1; }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 344 KB | Output is correct |
2 | Correct | 0 ms | 344 KB | Output is correct |
3 | Correct | 0 ms | 344 KB | Output is correct |
4 | Correct | 0 ms | 344 KB | Output is correct |
5 | Correct | 0 ms | 344 KB | Output is correct |
6 | Correct | 100 ms | 440 KB | Output is correct |
7 | Correct | 2 ms | 344 KB | Output is correct |
8 | Correct | 4 ms | 344 KB | Output is correct |
9 | Correct | 5 ms | 344 KB | Output is correct |
10 | Correct | 2 ms | 344 KB | Output is correct |
11 | Correct | 1 ms | 600 KB | Output is correct |
12 | Correct | 2 ms | 344 KB | Output is correct |
13 | Correct | 2 ms | 344 KB | Output is correct |
14 | Correct | 16 ms | 436 KB | Output is correct |
15 | Correct | 7 ms | 440 KB | Output is correct |
16 | Correct | 7 ms | 344 KB | Output is correct |
17 | Correct | 5 ms | 344 KB | Output is correct |
18 | Correct | 3 ms | 344 KB | Output is correct |
19 | Correct | 5 ms | 344 KB | Output is correct |
20 | Correct | 1 ms | 344 KB | Output is correct |
21 | Correct | 1 ms | 344 KB | Output is correct |
22 | Correct | 1 ms | 344 KB | Output is correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 344 KB | Output is correct |
2 | Correct | 0 ms | 344 KB | Output is correct |
3 | Correct | 0 ms | 344 KB | Output is correct |
4 | Correct | 0 ms | 344 KB | Output is correct |
5 | Correct | 0 ms | 344 KB | Output is correct |
6 | Correct | 100 ms | 440 KB | Output is correct |
7 | Correct | 2 ms | 344 KB | Output is correct |
8 | Correct | 4 ms | 344 KB | Output is correct |
9 | Correct | 5 ms | 344 KB | Output is correct |
10 | Correct | 2 ms | 344 KB | Output is correct |
11 | Correct | 1 ms | 600 KB | Output is correct |
12 | Correct | 2 ms | 344 KB | Output is correct |
13 | Correct | 2 ms | 344 KB | Output is correct |
14 | Correct | 16 ms | 436 KB | Output is correct |
15 | Correct | 7 ms | 440 KB | Output is correct |
16 | Correct | 7 ms | 344 KB | Output is correct |
17 | Correct | 5 ms | 344 KB | Output is correct |
18 | Correct | 3 ms | 344 KB | Output is correct |
19 | Correct | 5 ms | 344 KB | Output is correct |
20 | Correct | 1 ms | 344 KB | Output is correct |
21 | Correct | 1 ms | 344 KB | Output is correct |
22 | Correct | 1 ms | 344 KB | Output is correct |
23 | Incorrect | 204 ms | 456 KB | Too many queries. |
24 | Halted | 0 ms | 0 KB | - |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 344 KB | Output is correct |
2 | Correct | 0 ms | 344 KB | Output is correct |
3 | Correct | 0 ms | 344 KB | Output is correct |
4 | Correct | 0 ms | 344 KB | Output is correct |
5 | Correct | 0 ms | 344 KB | Output is correct |
6 | Correct | 0 ms | 344 KB | Output is correct |
7 | Incorrect | 200 ms | 344 KB | Too many queries. |
8 | Halted | 0 ms | 0 KB | - |