#include <bits/stdc++.h>
using namespace std;
struct node {
  long long x1, y1, x2, y2;
  long long area() const {
    if (x2 < x1 || y2 < y1)
      return 0;
    else
      return (x2 - x1) * (y2 - y1);
  }
};
node its(node a, node b) {
  node res;
  res.x1 = max(a.x1, b.x1);
  res.x2 = min(a.x2, b.x2);
  res.y1 = max(a.y1, b.y1);
  res.y2 = min(a.y2, b.y2);
  return res;
}
int main() {
  node w, b1, b2;
  cin >> w.x1 >> w.y1 >> w.x2 >> w.y2;
  cin >> b1.x1 >> b1.y1 >> b1.x2 >> b1.y2;
  cin >> b2.x1 >> b2.y1 >> b2.x2 >> b2.y2;
  long long res = w.area() - its(w, b1).area() - its(w, b2).area() +
                  its(w, its(b1, b2)).area();
  if (res > 0)
    cout << "YES\n";
  else
    cout << "NO\n";
}
