제출 #924959

#제출 시각아이디문제언어결과실행 시간메모리
924959sleepntsheepBest Place (NOI17_bestplace)C++17
3 / 100
30 ms2652 KiB
#include <iostream> #include <fstream> #include <iomanip> #include <cmath> #include <cassert> #include <cstring> #include <vector> #include <algorithm> #include <deque> #include <set> #include <utility> #include <array> #include <complex> using u32 = unsigned; using i32 = int; using i64 = long long; using u64 = unsigned long long; using f64 = double; using f80 = long double; using namespace std; using pt = complex<f80>; #define ALL(x) begin(x), end(x) #define ShinLena cin.tie(nullptr)->sync_with_stdio(false); #define N 200005 int n, x[N], y[N], b[N], zx, zy;; int main() { ShinLena; cin >> n; for (int i = 1; i <= n; ++i) cin >> x[i] >> y[i], b[i] = i; sort(b+1, b+1+n, [](int i, int j){ return x[i] < x[j]; }); if (1 or n&1) zx = x[n/2+1]; else zx = (x[n/2] + x[n/2+1]) / 2; sort(b+1, b+1+n, [](int i, int j){ return y[i] < y[j]; }); if (1 or n&1) zy = y[n/2+1]; else zy = (y[n/2] + y[n/2+1]) / 2; cout << zx << ' ' << zy; 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...