Submission #840381

# Submission time Handle Problem Language Result Execution time Memory
840381 2023-08-31T10:25:45 Z heavylightdecomp Choreography (IOI23_choreography) C++17
7 / 100
89 ms 9128 KB
#include<bits/stdc++.h>
using namespace std;
const int maxn = 1e5+5;
int orz[maxn], delt[maxn], N, ch;
void init(int n, vector<int> p) {
    N = n;
    for(int i = 0; i < N; i++) {
        orz[p[i]] = i;
    }
    for(int i = 0; i < N; i++) delt[i] = i;
}
void move_right(int K) {
    ch += K;
}
void move_left(int K) {
    ch += -K;
}
void swap_places() {

}
void move_around() {

}
int get_position(int D) {
    int pos = delt[orz[D]] + ch;
    while(pos >= N) {
        pos -= N;
    }
    while(pos < 0) {
        pos += N;
    }
    return pos;
}
# Verdict Execution time Memory Grader output
1 Correct 89 ms 9112 KB Output is correct
2 Correct 68 ms 9100 KB Output is correct
3 Correct 68 ms 9096 KB Output is correct
4 Correct 70 ms 9128 KB Output is correct
5 Correct 49 ms 6648 KB Output is correct
6 Correct 47 ms 6644 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 340 KB 5th lines differ - on the 1st token, expected: '411', found: '410'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 57 ms 8700 KB 16th lines differ - on the 1st token, expected: '54117', found: '49341'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 57 ms 8700 KB 16th lines differ - on the 1st token, expected: '54117', found: '49341'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 89 ms 9112 KB Output is correct
2 Correct 68 ms 9100 KB Output is correct
3 Correct 68 ms 9096 KB Output is correct
4 Correct 70 ms 9128 KB Output is correct
5 Correct 49 ms 6648 KB Output is correct
6 Correct 47 ms 6644 KB Output is correct
7 Incorrect 57 ms 8700 KB 16th lines differ - on the 1st token, expected: '54117', found: '49341'
8 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 89 ms 9112 KB Output is correct
2 Correct 68 ms 9100 KB Output is correct
3 Correct 68 ms 9096 KB Output is correct
4 Correct 70 ms 9128 KB Output is correct
5 Correct 49 ms 6648 KB Output is correct
6 Correct 47 ms 6644 KB Output is correct
7 Incorrect 1 ms 340 KB 5th lines differ - on the 1st token, expected: '411', found: '410'
8 Halted 0 ms 0 KB -