#include <bits/stdc++.h>
using namespace std;
long long mod = 1e9 + 7;
struct rectangle {
  long long x1, y1, x2, y2;
  void read() { cin >> x1 >> y1 >> x2 >> y2; }
  long long area() { return (x2 - x1) * (y2 - y1); }
  void print() { cout << x1 << " " << y1 << " " << x2 << " " << y2 << endl; }
};
void normalize(rectangle src, rectangle& to_be) {
  long long left = src.x1;
  long long right = src.x2;
  long long top = src.y2;
  long long bottom = src.y1;
  to_be.x1 = max(to_be.x1, left);
  if (to_be.x1 > right) to_be.x1 = right;
  to_be.x2 = min(to_be.x2, right);
  if (to_be.x2 < left) to_be.x2 = left;
  to_be.y1 = max(to_be.y1, bottom);
  if (to_be.y1 > top) to_be.y1 = top;
  to_be.y2 = min(to_be.y2, top);
  if (to_be.y2 < bottom) to_be.y2 = bottom;
}
long long intersect(rectangle& a, rectangle& b) {
  long long x1 = max(a.x1, b.x1);
  long long x2 = min(a.x2, b.x2);
  long long y1 = max(a.y1, b.y1);
  long long y2 = min(a.y2, b.y2);
  if (x1 >= x2 || y1 >= y2) return 0;
  return (x2 - x1) * (y2 - y1);
}
int32_t main() {
  rectangle a, b, c;
  a.read();
  b.read();
  c.read();
  normalize(a, b);
  normalize(a, c);
  if (a.area() == b.area() + c.area() - intersect(b, c))
    cout << "NO" << endl;
  else
    cout << "YES" << endl;
}
