#include using namespace std; #define LL long long #define F first #define S second #define MP make_pair #define PB push_back #define SZ(a) (int)(a.size()) #define BS(vec,val) (int)(lower_bound(vec.begin(),vec.end(),val) - vec.begin()) #define bitcount __builtin_popcountll #define LET(it,container) __typeof(container.begin()) it(container.begin()) #define ITER(it,container) for(__typeof(container.begin()) it=container.begin();it!=container.end();it++) #define PREC cout << setprecision(10) << fixed; #define FIO ios_base::sync_with_stdio(0); cin.tie(NULL); #define DB(x) cerr << #x << ": " << x << " "; //-std=c++11 //#define TRACE #ifdef TRACE #define trace(...) __f(#__VA_ARGS__, __VA_ARGS__) template void __f(const char* name, Arg1&& arg1){ cerr << name << " : " << arg1 << std::endl; } template void __f(const char* names, Arg1&& arg1, Args&&... args){ const char* comma = strchr(names + 1, ',');cerr.write(names, comma - names) << " : " << arg1<<" | ";__f(comma+1, args...); } #else #define trace(...) #endif //FILE *fin = freopen("in","r",stdin); //FILE *fout = freopen("out","w",stdout); #define endl "\n" const double PI = acos(-1.0); const int MOD = 1e9 + 7; const int INF = 1e9 + 9; const int MX = 1e5 + 5; int main() { int q; cin >> q; while(q--) { int n; int x[15],y[15]; cin >> n; for(int i=0;i> x[i] >> y[i]; int mix,mx; int miy,may; mix = miy = INF; mx = may = -INF; for(int i=0;i