/** ========================================** ** Bismillahi-Rahamanirahim. ** ** @Author: A Asif Khan Chowdhury ** ** ========================================**/ #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; #define Set(N, j) (N|(1< #define pb push_back #define open freopen("D:/a.txt", "r", stdin); #define write freopen("D:/b.txt","w", stdout); #define inf (1ll<<28) #define ll long long #define ull unsigned ll #define mod 1000000007 #define gc getchar #define ls(n) (n<<1) #define rs(n) ls(n)|1 #define MID(a,b) ((a+b)>>1) #define fs first #define sc second #define mx 100010 templateinline bool read(T &x) { int c=getchar(); int sgn=1; while((~c&&c<'0')||c>'9') { if(c=='-')sgn=-1; c=getchar(); } for(x=0; ~c&&'0'<=c&&c<='9'; c=getchar())x=x*10+c-'0'; x*=sgn; return ~c; } //int X[]= {-1, -1, -1, 0, 1, 1, 1, 0}; //x 8 direction //int Y[]= {-1, 0, +1, 1, 1, 0, -1, -1}; //y 8 direction int X[]= {-1, 0, 1, 0}; //x 4 direction int Y[]= { 0, 1, 0, -1}; //y 4 direction pii pnt[12]; int main() { #ifdef DEBUG freopen("/Users/abuasifkhan/Desktop/Programming/ProblemSolving/ProblemSolving/a.in", "r", stdin); // freopen("/Users/abuasifkhan/Desktop/Programming/ProblemSolving/ProblemSolving/b.out", "w", stdout); #endif int n,q; read(n); while(n--){ read(q); int xmin, xmax, ymin, ymax; for(int i=1;i<=q;i++){ read(pnt[i].fs);read(pnt[i].sc); if(i==1){ xmin = xmax = pnt[i].fs; ymin = ymax = pnt[i].sc; } ymin = min(ymin, pnt[i].sc); ymax = max(ymax, pnt[i].sc); xmin = min(xmin, pnt[i].fs); xmax = max(xmax, pnt[i].fs); } bool flag= true; for(int i=1;i<=q;i++){ // cout<xmin and pnt[i].fsymin and pnt[i].sc