#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long t, n, m, i, j, k;
  long long x1, x2, x3, x4, x5, x6, y1, y2, y3, y4, y5, y6;
  cin >> x1 >> y1 >> x2 >> y2;
  cin >> x3 >> y3 >> x4 >> y4;
  cin >> x5 >> y5 >> x6 >> y6;
  n = (x2 - x1) * (y2 - y1);
  i = max(x1, x3);
  j = min(x4, x2);
  long long x = j - i;
  if (x < 0) x = 0;
  i = max(y1, y3);
  j = min(y2, y4);
  long long y = j - i;
  if (y < 0) y = 0;
  n -= (x * y);
  if (n == 0)
    cout << "NO";
  else {
    i = max(x1, x5);
    j = min(x2, x6);
    x = j - i;
    if (x < 0) x = 0;
    i = max(y1, y5);
    j = min(y2, y6);
    y = j - i;
    if (y < 0) y = 0;
    n -= (x * y);
    i = max(x3, max(x1, x5));
    j = min(x4, min(x2, x6));
    x = j - i;
    if (x < 0) x = 0;
    i = max(y3, max(y1, y5));
    j = min(y4, min(y2, y6));
    y = j - i;
    if (y < 0) y = 0;
    n += (x * y);
    if (n == 0)
      cout << "NO";
    else
      cout << "YES";
  }
}
