이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
//#pragma GCC optimize("Ofast,unroll-loops")
//#pragma GCC target("avx,avx2,sse,sse2")
#include <bits/stdc++.h>
using namespace std;
//#define int long long
typedef long long ll;
typedef vector<int> vi;
typedef vector<vector<int>> vvi;
typedef set<int> si;
typedef map<int, int> mi;
#define fst first;
#define scnd second;
#define pb push_back
#define ins insert
#define nl '\n'
#define all(v) (v).begin(), (v).end();
#define allR(v) (v).rbegin(), (v).rend();
#define sorta(v) sort((v).begin(),(v).end());
#define sortd(x) sort((x).rbegin(), (x).rend());
#define loop(i, a, t) for (int (i)=a; (i)<=(t); (i)++)
#define loopr(i, a, b) for (int (i)=a; (i)>=(b); (i)--)
#define FILE freopen("input.txt", "r", stdin); freopen("output.txt", "w", stdout);
#define faster ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0);
const int inf = 1e9 + 10;
void solve() {
int n;
cin>>n;
vector<int> a(n);
vector<int> b(n);
for(int i=0; i<n ; i++ )
{
cin>>a[i] >> b[i];
}
sorta(a);
sorta(b);
cout<<a[a.size()/2]<<" "<<b[b.size()/2];
}
signed main() {
faster
int t = 1;
//cin>>t;
while (t--) {
solve();
}
return 0;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |