#include <bits/stdc++.h>
using namespace std;
long long power(long long a, long long b, long long modi) {
  long long res = 1;
  while (b) {
    if (b % 2) {
      res = (res * a) % modi;
    }
    b /= 2;
    a = (a * a) % modi;
  }
  return res;
}
long long dirx[] = {-1, -1, -1, 0, 0, 1, 1, 1};
long long diry[] = {-1, 0, 1, -1, 1, -1, 0, 1};
long long dx[] = {-1, 1, 0, 0};
long long dy[] = {0, 0, -1, 1};
long long n, m, k;
long long cur, sum, res, ans, x, y, z, val = 1e15;
long long a[1000005], b[1000005], c[1000005];
long long cal(long long x1, long long y1, long long x2, long long y2) {
  if (x1 >= x2 || y1 >= y2) return 0;
  return (y2 - y1) * (x2 - x1);
}
int main() {
  long long x1, x2, x3, x4, x5, x6;
  long long y1, y2, y3, y4, y5, y6;
  cin >> x1 >> y1 >> x2 >> y2;
  cin >> x3 >> y3 >> x4 >> y4;
  cin >> x5 >> y5 >> x6 >> y6;
  x3 = max(x3, x1);
  x4 = min(x2, x4);
  y3 = max(y3, y1);
  y4 = min(y2, y4);
  x5 = max(x5, x1);
  x6 = min(x2, x6);
  y5 = max(y5, y1);
  y6 = min(y2, y6);
  long long area = cal(x1, y1, x2, y2);
  long long area_ = cal(x3, y3, x4, y4) + cal(x5, y5, x6, y6);
  x3 = max(x3, x5);
  x4 = min(x6, x4);
  y3 = max(y3, y5);
  y4 = min(y6, y4);
  area_ -= cal(x3, y3, x4, y4);
  if (area == area_) {
    cout << "NO";
  } else
    cout << "YES";
  return 0;
}
