Submission #839548

#TimeUsernameProblemLanguageResultExecution timeMemory
839548model_codeChoreography (IOI23_choreography)C++17
10 / 100
67 ms6216 KiB
// correct/solution-subtask3.cpp #include "choreography.h" #include <vector> int n, cnt = 0; std::vector<int> p, inv; void init(int N, std::vector<int> P){ n = N; p = P; inv.resize(n); for(int i = 0; i < n; i++){ inv[p[i]] = i; } } void move_right(int K) {} void move_left(int K) {} void swap_places() {} void move_around() { ++cnt; } int get_position(int D){ return cnt&1 ? p[D] : inv[D]; }
#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...