func_code_string: #include <bits/stdc++.h>   #pragma GCC optimize( Ofast )   #pragma GCC optimize( unroll-loops )   #pragma GCC optimize( -ffloat-store )   #pragma GCC optimize( -fno-defer-pop )   long long power(long long a, long long b, long long m) {     if (b == 0) return 1;     if (b == 1) return a % m;     long long t = power(a, b / 2, m);     t = (t * t) % m;     if (b & 1) t = (t * a) % m;     return t;   }   using namespace std;   int main() {     ;     ios_base::sync_with_stdio(false);     cin.tie(NULL);     cout.tie(NULL);     ;     long long t;     cin >> t;     while (t--) {       long long a, b, c, d;       cin >> a >> b >> c >> d;       long long x, y, x1, y1, x2, y2;       cin >> x >> y >> x1 >> y1 >> x2 >> y2;       if (x2 - x1 == 0 && (a != 0 || b != 0)) {         cout <<  NO  << endl;         continue;       }       if (y2 - y1 == 0 && (c != 0 || d != 0)) {         cout <<  NO  << endl;         continue;       }       long long disx, disy;       disx = b - a;       disy = d - c;       if (0 <= disx) {         if (x2 - x < disx) {           cout <<  NO  << endl;           continue;         }       } else {         if (x - x1 < (-disx)) {           cout <<  NO  << endl;           continue;         }       }       if (0 <= disy) {         if (y2 - y < disy) {           cout <<  NO  << endl;           continue;         }       } else {         if (y - y1 < (-disy)) {           cout <<  NO  << endl;           continue;         }       }       cout <<  YES  << endl;     }   }   