func_code_string: #include <bits/stdc++.h>   using namespace std;   struct node {     int x, y;   } A[10005], B[10005], CA[10005], CB[10005];   int tim, qim;   node operator+(node a, node b) { return node{a.x + b.x, a.y + b.y}; }   node operator-(node a, node b) { return node{a.x - b.x, a.y - b.y}; }   int operator*(node a, node b) { return a.x * b.x + a.y * b.y; }   int operator/(node a, node b) { return a.x * b.y - a.y * b.x; }   bool operator<(node a, node b) {     if (a.x == b.x) return a.y > b.y;     return a.x < b.x;   }   void convex_hull(node p[], node c[], int n, int &tp) {     sort(p + 1, p + n + 1);     tp = 0;     for (int i = 1; i <= n; i++) {       while (tp > 1 && (c[tp] - p[i]) / (c[tp - 1] - p[i]) >= 0) tp--;       c[++tp] = p[i];     }     int k = tp--;     for (int i = n; i >= 1; i--) {       while (tp > k && (c[tp] - p[i]) / (c[tp - 1] - p[i]) >= 0) tp--;       c[++tp] = p[i];     }     tp--;   }   bool solve(node a[], node b[], int na, int nb) {     random_shuffle(a + 1, a + na + 1);     random_shuffle(b + 1, b + nb + 1);     for (int i = 1; i <= na; i++)       for (int j = i + 1, k; j <= na; j++) {         node pa = a[i], pb = a[j];         double lp = -1e100, rp = 1e100, inf = 1e100;         for (k = 1; k <= na; k++) {           if (k == i) continue;           if (k == j) continue;           int ta = (a[k] - pa) * (a[k] - pb);           int tb = (pa - a[k]) / (pa - pb);           assert(tb != 0);           if (tb == 0) {             if (ta > 0)               break;             else               continue;           }           double r = (double)ta / tb;           if (tb < 0)             rp = min(rp, r);           else if (tb > 0)             lp = max(lp, r);           if (lp > rp) break;         }         if (k <= na || lp > rp) continue;         for (k = 1; k <= nb; k++) {           int ta = (b[k] - pa) * (b[k] - pb);           int tb = (pa - b[k]) / (pa - pb);           if (tb == 0) {             if (ta <= 0)               break;             else               continue;           }           double r = (double)ta / tb;           if (tb > 0)             rp = min(rp, r);           else if (tb < 0)             lp = max(lp, r);           if (lp >= rp) break;         }         if (k > nb && lp < rp) return 1;       }     return 0;   }   int main() {     srand(time(NULL));     clock_t st, ed;     double totaltime;     st = clock();     int n, m, cn, cm, i;     scanf( %d%d , &n, &m);     for (i = 1; i <= n; i++) scanf( %d%d , &A[i].x, &A[i].y);     for (i = 1; i <= m; i++) scanf( %d%d , &B[i].x, &B[i].y);     if (n == 1 || m == 1) return puts( YES ), 0;     convex_hull(A, CA, n, cn);     convex_hull(B, CB, m, cm);     if (solve(CA, B, cn, m) || solve(CB, A, cm, n))       puts( YES );     else       puts( NO );     ed = clock();     totaltime = (double)(ed - st) / CLOCKS_PER_SEC;   }   