#include <bits/stdc++.h>
int max(int a, int b) { return a > b ? a : b; }
int min(int a, int b) { return a < b ? a : b; }
int pan(int aa, int bb, int cc, int dd) {
  if (aa <= 0 || bb <= 0 || cc <= 0 || dd <= 0) return 0;
  if (aa >= cc && bb >= dd) return 1;
  return 0;
}
int main() {
  int n, i, f, a, b, x, y, c, d, a1, b1, c1, d1, x1, y1;
  while (~scanf("%d%d", &x1, &y1)) {
    scanf("%d%d%d%d", &a1, &b1, &c1, &d1);
    f = 0;
    a = max(a1, b1);
    b = min(a1, b1);
    x = max(x1, y1);
    y = min(x1, y1);
    c = max(c1, d1);
    d = min(c1, d1);
    if (a <= y) {
      i = pan(max(x - b, y), min(x - b, y), c, d);
      if (i == 1) {
        f = 1;
      }
      i = pan(max(x, y - a), min(x, y - a), c, d);
      if (i == 1) {
        f = 1;
      }
    }
    if (a <= x) {
      if (b <= y) {
        i = pan(max(y - b, x), min(y - b, x), c, d);
        if (i == 1) {
          f = 1;
        }
        i = pan(max(x - a, y), min(x - a, y), c, d);
        if (i == 1) {
          f = 1;
        }
      }
    }
    if (f == 1)
      printf("YES\n");
    else
      printf("NO\n");
  }
}
