# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
793956 | 2023-07-26T08:18:58 Z | MetalPower | Super Dango Maker (JOI22_dango3) | C++17 | 1770 ms | 712 KB |
#include "dango3.h" #include <bits/stdc++.h> using namespace std; bool ans[10005]; vector<int> pos[30]; void Solve(int N, int M) { for(int i = 1; i <= N * M; i++){ int l = 1, r = M; while(l < r){ int mid = l + r >> 1; memset(ans, 0, sizeof ans); for(int j = 1; j <= mid; j++){ for(int x : pos[j]) ans[x] = true; } ans[i] = true; vector<int> vec; for(int i = 1; i <= N * M; i++){ if(!ans[i]) vec.push_back(i); } int curr = Query(vec); if(curr >= M - mid) r = mid; else l = mid + 1; } pos[l].push_back(i); } }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 0 ms | 340 KB | Wrong Answer [8] |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 14 ms | 384 KB | Wrong Answer [8] |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 444 ms | 600 KB | Wrong Answer [8] |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 1770 ms | 712 KB | Wrong Answer [8] |
2 | Halted | 0 ms | 0 KB | - |