#include <bits/stdc++.h>
using namespace std;
bool check(long long a, long long b, long long c, long long d) {
  if (c <= b && d >= a)
    return true;
  else
    return false;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long a, b, c, d;
  cin >> a >> b >> c >> d;
  long long a1, b1, c1, d1;
  cin >> a1 >> b1 >> c1 >> d1;
  long long a2, b2, c2, d2;
  cin >> a2 >> b2 >> c2 >> d2;
  long long white = abs(a - c) * abs(b - d);
  long long area = 0, area_ = 0, com = 0;
  if (check(a, c, a1, c1) && check(b, d, b1, d1)) {
    area = abs(max(a, a1) - min(c, c1)) * abs(max(b, b1) - min(d, d1));
    a1 = max(a, a1);
    b1 = max(b, b1);
    c1 = min(c, c1);
    d1 = min(d, d1);
  }
  if (check(a, c, a2, c2) && check(b, d, b2, d2)) {
    area_ = abs(max(a, a2) - min(c, c2)) * abs(max(b, b2) - min(d, d2));
    a2 = max(a, a2);
    b2 = max(b, b2);
    c2 = min(c, c2);
    d2 = min(d, d2);
  }
  if (area && area_) {
    com = abs(max(a1, a2) - min(c1, c2)) * abs(max(b1, b2) - min(d1, d2));
  }
  long long ans = white + com - area - area_;
  if (ans > 0)
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
