답안 #17325

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
17325 2015-11-20T23:21:38 Z tncks0121 돌 무게 재기 (IZhO11_stones) C++14
0 / 100
983 ms 40984 KB
#include <stdio.h>
#include <stdlib.h>
#include <bits/stdc++.h>

using namespace std;

int N;
int X[100][100500];
long long L[100], R[100];
int main() {
  scanf("%d", &N);
  for(int i = 0; i < 100; i++) {
    for(int j = 0; j < N; j++) X[i][j] = rand() % 10000 + 1;
    sort(X[i], X[i] + N);
  }
  
  while(N--) {
    int P, S; scanf("%d%d", &P, &S);
    bool a1 = false, a2 = false;
    for(int i = 0; i < 100; i++) {
      (S == 1 ? L : R)[i] += X[i][P - 1];
      if(L[i] < R[i]) a1 = true;
      if(L[i] > R[i]) a2 = true;
    }
    if(a1 ^ a2) {
      puts(a1 ? "<" : ">");
    }else {
      puts("?");
    }
  }
  
  return 0;
}
# 결과 실행 시간 메모리 Grader output
1 Incorrect 0 ms 40984 KB Output isn't correct - 5th words differ - expected: '?', found: '<'
2 Incorrect 0 ms 40984 KB Output isn't correct - 6th words differ - expected: '?', found: '>'
3 Incorrect 0 ms 40984 KB Output isn't correct - 8th words differ - expected: '?', found: '<'
4 Incorrect 0 ms 40984 KB Output isn't correct - 3rd words differ - expected: '?', found: '<'
5 Incorrect 4 ms 40984 KB Output isn't correct - 3rd words differ - expected: '?', found: '>'
6 Incorrect 4 ms 40984 KB Output isn't correct - 3rd words differ - expected: '?', found: '<'
7 Incorrect 4 ms 40984 KB Output isn't correct - 17th words differ - expected: '?', found: '<'
8 Incorrect 5 ms 40984 KB Output isn't correct - 3rd words differ - expected: '?', found: '<'
9 Incorrect 13 ms 40984 KB Output isn't correct - 7th words differ - expected: '?', found: '<'
10 Incorrect 83 ms 40984 KB Output isn't correct - 8th words differ - expected: '?', found: '<'
11 Incorrect 569 ms 40984 KB Output isn't correct - 4th words differ - expected: '?', found: '<'
12 Incorrect 932 ms 40984 KB Output isn't correct - 4th words differ - expected: '?', found: '>'
13 Incorrect 973 ms 40984 KB Output isn't correct - 2nd words differ - expected: '>', found: '?'
14 Incorrect 974 ms 40984 KB Output isn't correct - 2nd words differ - expected: '<', found: '?'
15 Incorrect 961 ms 40984 KB Output isn't correct - 26th words differ - expected: '?', found: '<'
16 Incorrect 973 ms 40984 KB Output isn't correct - 9th words differ - expected: '?', found: '>'
17 Incorrect 979 ms 40984 KB Output isn't correct - 2nd words differ - expected: '>', found: '?'
18 Incorrect 974 ms 40984 KB Output isn't correct - 4th words differ - expected: '?', found: '<'
19 Incorrect 981 ms 40984 KB Output isn't correct - 17th words differ - expected: '?', found: '>'
20 Incorrect 983 ms 40984 KB Output isn't correct - 4th words differ - expected: '<', found: '?'
21 Incorrect 957 ms 40984 KB Output isn't correct - 11th words differ - expected: '?', found: '<'
22 Incorrect 974 ms 40984 KB Output isn't correct - 11th words differ - expected: '?', found: '<'
23 Incorrect 978 ms 40984 KB Output isn't correct - 2nd words differ - expected: '>', found: '?'
24 Incorrect 972 ms 40984 KB Output isn't correct - 3rd words differ - expected: '?', found: '<'
25 Incorrect 969 ms 40984 KB Output isn't correct - 6th words differ - expected: '?', found: '>'