Submission #791384

#TimeUsernameProblemLanguageResultExecution timeMemory
791384ttamxRoads (CEOI20_roads)C++14
15 / 100
14 ms2288 KiB
#include<bits/stdc++.h> using namespace std; typedef long long ll; const int N=1e5+5; int n; vector<tuple<ll,ll,ll,ll>> vec; int main(){ cin.tie(nullptr)->sync_with_stdio(false); cin >> n; for(int i=1;i<=n;i++){ ll a,b,c,d; cin >> a >> b >> c >> d; if(b>d)swap(a,c),swap(b,d); vec.emplace_back(a,b,c,d); } sort(vec.begin(),vec.end()); for(int i=1;i<n;i++){ cout << get<2>(vec[i-1]) << " " << get<3>(vec[i-1]) << " " << get<0>(vec[i]) << " " << get<1>(vec[i]) << "\n"; } }
#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...