제출 #321071

#제출 시각아이디문제언어결과실행 시간메모리
321071techiehere08Best Place (NOI17_bestplace)C++14
100 / 100
48 ms3052 KiB
#include <bits/stdc++.h> using namespace std; int main(){ int n, A[100005], B[100005]; scanf("%d", &n); for(int i = 0; i < n; i++){ scanf("%d%d", A + i, B + i); } sort(A, A + n), sort(B, B + n); n -= 1; n /= 2; printf("%d %d\n", A[n], B[n]); return 0; }

컴파일 시 표준 에러 (stderr) 메시지

bestplace.cpp: In function 'int main()':
bestplace.cpp:7:8: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
    7 |   scanf("%d", &n);
      |   ~~~~~^~~~~~~~~~
bestplace.cpp:9:10: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
    9 |     scanf("%d%d", A + i, B + i);
      |     ~~~~~^~~~~~~~~~~~~~~~~~~~~~
#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...