Submission #998667

#TimeUsernameProblemLanguageResultExecution timeMemory
998667SharkySuper Dango Maker (JOI22_dango3)C++17
7 / 100
2423 ms756 KiB
// i hope this works #include "dango3.h" #include <bits/stdc++.h> using namespace std; namespace { } // namespace random_device rd; mt19937 g(rd()); void Solve(int N, int M) { vector<int> p; for (int i = 1; i <= N * M; i++) p.push_back(i); shuffle(p.begin(), p.end(), g); vector<int> sus(N * M + 1, 0); for (int it = 1; it <= M; it++) { vector<int> amogus; for (int ii = 1; ii <= N * M; ii++) { int i = p[ii - 1]; if (sus[i]) continue; amogus.push_back(i); sus[i] = 1; vector<int> alice; for (int j = 1; j <= N * M; j++) if (sus[j] != 1) alice.push_back(j); if (Query(alice) < M - 1) { amogus.pop_back(); sus[i] = 0; } } Answer(amogus); for (auto& baby : amogus) sus[baby] = 2; } }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...