#include <bits/stdc++.h>
using namespace std;
struct taskas {
  long long x, y;
  taskas() {}
  taskas(long long x, long long y) : x(x), y(y) {}
  void get() { cin >> x >> y; }
  bool operator<(taskas a) { return x * a.y > a.x * y; }
  bool operator>(taskas a) { return x * a.y < a.x * y; }
  long double angle() { return atan2(y, x); }
};
taskas operator-(taskas a, taskas b) { return taskas(a.x - b.x, a.y - b.y); }
taskas operator^(taskas a, taskas b) { return b - a; }
taskas operator*(taskas a, taskas b) {
  return taskas(a.x * b.x - a.y * b.y, a.x * b.y + a.y * b.x);
}
long long crossP(taskas a, taskas b) { return a.x * b.y - b.x * a.y; }
long long area(taskas A, taskas B, taskas C) {
  return abs((A.x + B.x) * (A.y - B.y) + (B.x + C.x) * (B.y - C.y) +
             (C.x + A.x) * (C.y - A.y));
}
struct convex {
  vector<taskas> V;
  convex(long long n) : V(n) {}
  void fix() {
    long long y = 10000000000ll;
    long long k = 0;
    vector<taskas> S = V;
    for (long long i = 0; i < V.size(); i++) {
      S[i] = V[i];
      if (y > V[i].y) {
        y = V[i].y;
        k = i;
      }
    }
    for (long long i = 0; i < V.size(); i++) V[i] = S[(i + k) % V.size()];
  }
  void get() {
    for (long long i = 0; i < V.size(); i++) V[i].get();
    fix();
  }
  bool inside(taskas a, long long i, long long j) {
    if ((V[0] ^ a).y < 0) return false;
    if ((V[0] ^ a) < (V[0] ^ V[j])) return false;
    if ((V[0] ^ a) > (V[0] ^ V[i])) return false;
    if (abs(i - j) <= 1) {
      if (area(a, V[i], V[j]) == 0) return false;
      return area(V[0], V[i], a) + area(V[0], V[j], a) + area(V[i], V[j], a) ==
             area(V[0], V[i], V[j]);
    } else {
      if (area(V[0], a, V[1]) == 0 || area(V[0], a, V[V.size() - 1]) == 0)
        return false;
      long long k = (i + j) / 2;
      if (inside(a, i, k) || inside(a, k, j)) return true;
    }
    return false;
  }
  bool inside(taskas a) { return inside(a, 1, V.size() - 1); }
};
int main() {
  ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL);
  long long n;
  cin >> n;
  convex A(n);
  A.get();
  long long m;
  cin >> m;
  while (m--) {
    taskas a;
    a.get();
    if (!A.inside(a)) {
      cout << "NO";
      return 0;
    }
  }
  cout << "YES";
  return 0;
}
