# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
23480 | 2017-05-10T02:38:15 Z | TAMREF | 이상한 수열 (OJUZ10_bizarre) | C++11 | 23 ms | 11392 KB |
#include <bits/stdc++.h> using namespace std; int S[200000], A[2000005], cnt[200000]; const int bias=1000000; int main(){ int N,M; scanf("%d",&N); for(int i=1;i<=N;i++){ scanf("%d",&S[i]); cnt[i]=cnt[i-1]+(A[S[i]+bias]++?0:1); } scanf("%d",&M); if(M<=N) return !printf("%d\n",S[M]); cnt[N+1]=cnt[N]; for(int i=N+2;i<=M;i++) cnt[i]=cnt[i-1]+(A[cnt[i-1]+bias]++?0:1); return !printf("%d\n",cnt[M]); }
Compilation message
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 11392 KB | Output is correct |
2 | Correct | 0 ms | 11392 KB | Output is correct |
3 | Correct | 0 ms | 11392 KB | Output is correct |
4 | Correct | 0 ms | 11392 KB | Output is correct |
5 | Correct | 0 ms | 11392 KB | Output is correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 11392 KB | Output is correct |
2 | Correct | 0 ms | 11392 KB | Output is correct |
3 | Correct | 0 ms | 11392 KB | Output is correct |
4 | Correct | 0 ms | 11392 KB | Output is correct |
5 | Correct | 0 ms | 11392 KB | Output is correct |
6 | Correct | 0 ms | 11392 KB | Output is correct |
7 | Correct | 0 ms | 11392 KB | Output is correct |
8 | Correct | 0 ms | 11392 KB | Output is correct |
9 | Correct | 0 ms | 11392 KB | Output is correct |
10 | Correct | 0 ms | 11392 KB | Output is correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Correct | 13 ms | 11392 KB | Output is correct |
2 | Correct | 0 ms | 11392 KB | Output is correct |
3 | Correct | 6 ms | 11392 KB | Output is correct |
4 | Correct | 3 ms | 11392 KB | Output is correct |
5 | Correct | 0 ms | 11392 KB | Output is correct |
6 | Correct | 3 ms | 11392 KB | Output is correct |
7 | Correct | 0 ms | 11392 KB | Output is correct |
8 | Correct | 0 ms | 11392 KB | Output is correct |
9 | Correct | 6 ms | 11392 KB | Output is correct |
10 | Correct | 16 ms | 11392 KB | Output is correct |
11 | Correct | 6 ms | 11392 KB | Output is correct |
12 | Correct | 0 ms | 11392 KB | Output is correct |
13 | Correct | 3 ms | 11392 KB | Output is correct |
14 | Correct | 3 ms | 11392 KB | Output is correct |
15 | Correct | 6 ms | 11392 KB | Output is correct |
# | 결과 | 실행 시간 | 메모리 | Grader output |
---|---|---|---|---|
1 | Halted | 0 ms | 0 KB | - |
2 | Runtime error | 23 ms | 11392 KB | Execution killed with signal 11 (could be triggered by violating memory limits) |