| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 13290 | 陈颖钧 | 坐标排序 | C++ | Accepted | 100 | 2 MS | 256 KB | 543 | 2025-09-17 21:52:35 |
#include<bits/stdc++.h> using namespace std; long long n,i; struct date{ int x,y; }a[9999999]; bool cmp(date x,date y){ if(x.x<y.x){ return true; }else if(x.x==y.x){ if(x.y<y.y){ return true; }else{ return false; } }else{ return false; } } int main(){ cin>>n; for(i=1;i<=n;i++){ cin>>a[i].x>>a[i].y; } sort(a+1,a+n+1,cmp); for(i=1;i<=n;i++){ cout<<a[i].x<<' '<<a[i].y<<endl; } return 0; }