Submission #3719

#TimeUsernameProblemLanguageResultExecution timeMemory
3719zzapcoderDivide into triangle (kriii1_D)C++98
1 / 1
0 ms1672 KiB
#include<iostream> #include<vector> #include<algorithm> #include<utility> using namespace std; #define pox pair<pair<int,int>,int> #define x first #define y second int main(){ int n; cin >> n; vector<pox > vp(3*n, make_pair(make_pair(0,0),0)); for(int i=0;i<3*n;++i){ cin>>vp[i].x.x>>vp[i].x.y; vp[i].y = i+1; } sort(vp.begin(), vp.end()); for(int i=0;i<vp.size();++i){ cout<<vp[i].y<<' '; if(i%3 == 2) cout<<endl; } }
#Verdict Execution timeMemoryGrader output
Fetching results...