Submission #531858

#TimeUsernameProblemLanguageResultExecution timeMemory
531858devariaotaBest Place (NOI17_bestplace)C++17
100 / 100
36 ms3808 KiB
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef double db; #define pairll pair<ll,ll> #define lpairll pair<pairll,ll> #define pb push_back #define mp make_pair #define fr first #define sc second #define repp(i,a,b) for(ll i = (a); i <= (b); i++) #define repm(i, a, b) for (ll i = (a); i >= (b); i--) #define repz(i, a, b) for (ll i = (a); i < (b); i++) const long long MOD = 1e9+7, N = 3e5 + 5, Q = 4e3+5; ll tc = 1, n, m=0,k, x[N], y[N]; string s, ye = "YES", no = "NO"; vector<ll> res; void fastt(){ ios_base::sync_with_stdio(0); cin.tie(NULL); cout.tie(NULL); } void input(){ cin >> n; repp(i,1,n) cin >> x[i] >> y[i]; } void solve(){ sort(x+1,x+n+1); sort(y+1,y+n+1); cout << x[n/2+1] << " " << y[n/2+1] << endl; } int main(){ // freopen("input.txt", "r", stdin); // freopen("output.txt", "w", stdout); fastt(); //cin >> tc; while(tc--){ input(); solve(); } } /* */
#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...