#include <bits/stdc++.h>
int main() {
  int h[6], w[6];
  int i, j, tmp;
  for (i = 0; i < 6; i++) {
    scanf("%d %d", &h[i], &w[i]);
    if (h[i] > w[i]) {
      tmp = h[i];
      h[i] = w[i];
      w[i] = tmp;
    }
  }
  for (i = 0; i < 6; i++) {
    for (j = 0; j + 1 < 6; j++) {
      if (h[j] > h[j + 1] || (h[j] == h[j] && w[j] > w[j + 1])) {
        tmp = h[j];
        h[j] = h[j + 1];
        h[j + 1] = tmp;
        tmp = w[j];
        w[j] = w[j + 1];
        w[j + 1] = tmp;
      }
    }
  }
  int a = 0, b = 0, c = 0;
  for (i = 0; i < 6; i++) {
    a ^= (h[i] * 10000 + w[i]);
    b ^= h[i];
    c ^= w[i];
  }
  if (a | b | c) {
    printf("no\n");
  } else {
    printf("yes\n");
  }
  return 0;
}
