#include #define FOR(i,a,b) for(int i = a; i < b; ++i) #define FORD(i,a,b) for(int i = a; i >= b; --i) #define pi pair #define vi vector #define vvi vector #define fi first #define se second #define ALL(c) (c).begin(),(c).end() #ifndef DEBUG #define endl (char)10 #endif using namespace std; using ll = long long; using ld = long double; const int MAX = 1100; vvi G(MAX); int n; struct P{ ll x,y; int i; }; P ps[MAX]; int main (){ ios_base::sync_with_stdio(false); cin.tie(0); cin>>n; ll a,b; FOR(i,0,n-1){ cin>>a>>b; } FOR(i,0,n){ cin>>a>>b; ps[i]={a,b,i}; } sort(ps,ps+n,[](P a,P b) { if(a.x==b.x) return a.y < b.y; return a.x < b.x; }); FOR(i,1,n){ cout<