#include <bits/stdc++.h>
using namespace std;
struct CC {
  long long x1, x2, y1, y2;
};
CC jiao(CC a, CC b) {
  CC c1;
  c1.x1 = max(a.x1, b.x1);
  c1.y1 = max(a.y1, b.y1);
  c1.x2 = min(a.x2, b.x2);
  c1.y2 = min(a.y2, b.y2);
  return c1;
}
int main() {
  CC w, b1, b2;
  cin >> w.x1 >> w.y1 >> w.x2 >> w.y2 >> b1.x1 >> b1.y1 >> b1.x2 >> b1.y2 >>
      b2.x1 >> b2.y1 >> b2.x2 >> b2.y2;
  CC j1 = jiao(w, b1);
  CC j2 = jiao(w, b2);
  CC j3 = jiao(j1, j2);
  long long s, s1, s2, s3;
  s = (w.x2 - w.x1) * (w.y2 - w.y1);
  if (j1.x1 > j1.x2 || j1.y1 > j1.y2)
    s1 = 0;
  else
    s1 = (j1.x2 - j1.x1) * (j1.y2 - j1.y1);
  if (j2.x1 > j2.x2 || j2.y1 > j2.y2)
    s2 = 0;
  else
    s2 = (j2.x2 - j2.x1) * (j2.y2 - j2.y1);
  if (j3.x1 > j3.x2 || j3.y1 > j3.y2)
    s3 = 0;
  else
    s3 = (j3.x2 - j3.x1) * (j3.y2 - j3.y1);
  if (s1 + s2 - s3 == s)
    cout << "NO" << endl;
  else
    cout << "YES" << endl;
  return 0;
}
