답안 #65275

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
65275 2018-08-07T09:32:42 Z gnoor 곤돌라 (IOI14_gondola) C++17
10 / 100
19 ms 4592 KB
#include "gondola.h"

#include <cmath>
#include <cstdio>

int valid(int n, int inputSeq[])
{
	int key=-1e9;
	int id=-1;
	int cur;
	for (int i=0;i<n;i++) {
		if (inputSeq[i]>n) continue;
		cur=i-inputSeq[i];
		if (key==-1e9) {
			key=cur;
			id=inputSeq[i];
		}
		if (inputSeq[i]<id) cur-=n;
		if (key!=cur) return 0;
	}
	return 1;
}

//----------------------

int replacement(int n, int gondolaSeq[], int replacementSeq[])
{
  return -2;
}

//----------------------

int countReplacement(int n, int inputSeq[])
{
  return -3;
}
# 결과 실행 시간 메모리 Grader output
1 Correct 3 ms 376 KB Output is correct
2 Correct 3 ms 480 KB Output is correct
3 Correct 2 ms 500 KB Output is correct
4 Correct 2 ms 560 KB Output is correct
5 Correct 2 ms 560 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 3 ms 560 KB Output is correct
2 Correct 2 ms 560 KB Output is correct
3 Correct 3 ms 560 KB Output is correct
4 Correct 2 ms 568 KB Output is correct
5 Correct 3 ms 568 KB Output is correct
6 Correct 8 ms 872 KB Output is correct
7 Correct 17 ms 1724 KB Output is correct
8 Correct 18 ms 2044 KB Output is correct
9 Correct 6 ms 2044 KB Output is correct
10 Correct 19 ms 2780 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 3 ms 2780 KB Output is correct
2 Correct 3 ms 2780 KB Output is correct
3 Correct 2 ms 2780 KB Output is correct
4 Correct 4 ms 2780 KB Output is correct
5 Correct 2 ms 2780 KB Output is correct
6 Correct 7 ms 2816 KB Output is correct
7 Correct 14 ms 3556 KB Output is correct
8 Correct 15 ms 4028 KB Output is correct
9 Correct 7 ms 4028 KB Output is correct
10 Correct 15 ms 4592 KB Output is correct
11 Incorrect 2 ms 4592 KB Output isn't correct
12 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 2 ms 4592 KB Integer -2 violates the range [0, 350000]
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 2 ms 4592 KB Integer -2 violates the range [0, 350000]
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 3 ms 4592 KB Integer -2 violates the range [0, 350000]
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 3 ms 4592 KB Integer -3 violates the range [0, 1000000008]
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 2 ms 4592 KB Integer -3 violates the range [0, 1000000008]
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 3 ms 4592 KB Integer -3 violates the range [0, 1000000008]
2 Halted 0 ms 0 KB -
# 결과 실행 시간 메모리 Grader output
1 Incorrect 2 ms 4592 KB Integer -3 violates the range [0, 1000000008]
2 Halted 0 ms 0 KB -