Submission #577474

#TimeUsernameProblemLanguageResultExecution timeMemory
577474hailBest Place (NOI17_bestplace)C++17
3 / 100
46 ms3044 KiB
#include <bits/stdc++.h> using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(nullptr); int N; cin>>N; vector<int> vec_x; vec_x.reserve(N); vector<int> vec_y; vec_y.reserve(N); int x, y; for(int i{0}; i<N; i++) { cin>>x>>y; vec_x.push_back(x); vec_y.push_back(y); } sort(vec_x.begin(), vec_x.end()); sort(vec_y.begin(), vec_y.end()); int a = vec_x[(N/2) - 1]; int b = vec_y[(N/2)-1]; cout<<a<<" "<<b; return 0; }
#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...