Submission #971485

#TimeUsernameProblemLanguageResultExecution timeMemory
971485CyberCowThe Collection Game (BOI21_swaps)C++17
0 / 100
0 ms344 KiB
// // --- Sample implementation for the task swaps --- // // To compile this program with the sample grader, place: // swaps.h swaps_sample.cpp sample_grader.cpp // in a single folder and run: // g++ swaps_sample.cpp sample_grader.cpp // in this folder. // #include "swaps.h" #include <vector> using namespace std; int color[100000]; void solve(int N, int V) { for (int i = 1; i < N; i++) { for (int j = 0; j < N; j++) { color[j] = 0; } for (int j = 0; j < N; j++) { if (color[j] == 0) { schedule(j + 1, (j + i) % N + 1); color[(j + i) % N] = 1; } } visit(); } vector<int> v; for (int i = 0; i < N; i++) { v.push_back(i + 1); } answer(v); }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...