#include <bits/stdc++.h>
using namespace std;
struct node {
  int x;
  int y;
};
int area(struct node a, struct node b, struct node c) {
  long long int ar = a.x * (long long int)(b.y - c.y) +
                     b.x * (long long int)(c.y - a.y) +
                     c.x * (long long int)(a.y - b.y);
  if (ar < 0)
    return -1;
  else if (ar > 0)
    return 1;
  else
    return 0;
}
int main() {
  int n, m;
  struct node a[100007], b[100007];
  scanf("%d", &n);
  for (int i = 0; i < n; i++) scanf("%d%d", &a[i].x, &a[i].y);
  scanf("%d", &m);
  for (int i = 0; i < m; i++) scanf("%d%d", &b[i].x, &b[i].y);
  for (int i = 0; i < m; i++) {
    struct node p = b[i];
    int l = 1, r = n - 1, mid;
    while (r - l > 1) {
      mid = (l + r) / 2;
      int q = area(a[0], a[mid], p);
      if (q >= 0)
        r = mid;
      else
        l = mid;
    }
    int res1 = area(a[0], a[l], p);
    int res2 = area(a[l], a[r], p);
    int res3 = area(a[r], a[0], p);
    if (res1 < 0 && res2 < 0 && res3 < 0)
      continue;
    else if ((res1 == 0 && l != 1 && res2 < 0 && res3 < 0))
      continue;
    else if (res3 == 0 && r != (n - 1) && res1 < 0 && res2 < 0)
      continue;
    else {
      printf("NO\n");
      return 0;
    }
  }
  printf("YES\n");
  return 0;
}
