#include <bits/stdc++.h>
using namespace std;
long long int maxN = 1e+9 + 7;
long long int MaxN = 1e+5 + 7;
vector<long long int> sprime;
vector<char> prime(MaxN, true);
void sieve(long long int n) {
  prime[0] = prime[1] = false;
  for (long long int i = 2; i <= n; ++i) {
    if (prime[i]) {
      sprime.push_back(i);
      for (long long int j = 2 * i; j <= n; j += i) prime[j] = false;
    }
  }
}
long long int stoin(string s) {
  long long int N;
  stringstream geek(s);
  geek >> N;
  return N;
}
long long int gcd(long long int a, long long int b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
long long int fastpowMOD(long long int a, long long int p, long long int MOD) {
  if (p == 0) return 1;
  long long int z = fastpowMOD(a, p / 2, MOD);
  z = (z * z) % MOD;
  if (p % 2) z = (z * a) % MOD;
  return z;
}
long long int fastpow(long long int a, long long int p) {
  if (p == 0) return 1;
  long long int z = fastpow(a, p / 2);
  z = (z * z);
  if (p % 2) z = (z * a);
  return z;
}
void print(vector<long long int> A) {
  int N = A.size();
  for (int i = 0; i < N; i++) printf("%lld ", A[i]);
  printf("\n");
}
vector<long long int> ret(vector<long long int> A, vector<long long int> B) {
  vector<long long int> ans(5, 0);
  ans[0] = max(A[0], B[0]);
  ans[1] = max(A[1], B[1]);
  ans[2] = min(A[2], B[2]);
  ans[3] = min(A[3], B[3]);
  if (ans[0] >= ans[2] || ans[1] >= ans[3]) {
    ans[0] = A[0];
    ans[1] = A[1];
    ans[2] = A[0];
    ans[3] = A[1];
  }
  return ans;
}
long long int area(vector<long long int> A) {
  long long int ans = (A[2] - A[0]) * (A[3] - A[1]);
  return ans;
}
void solve() {
  vector<long long int> A(5), B(5), C(5);
  for (int i = 0; i < 4; i++) cin >> A[i];
  for (int i = 0; i < 4; i++) cin >> B[i];
  for (int i = 0; i < 4; i++) cin >> C[i];
  vector<long long int> AA = ret(A, B);
  vector<long long int> BB = ret(A, C);
  vector<long long int> CC = ret(AA, BB);
  if (area(A) - area(AA) - area(BB) + area(CC) > 0)
    printf("YES\n");
  else
    printf("NO\n");
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  int T = 1, t;
  t = T;
  while (T--) {
    solve();
  }
}
