Submission #494776

#TimeUsernameProblemLanguageResultExecution timeMemory
494776Kushagra_JBest Place (NOI17_bestplace)C++17
100 / 100
36 ms1220 KiB
//#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 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...