#include <bits/stdc++.h>
using namespace std;
__attribute__((constructor)) void initial() {
  cin.tie(0);
  ios::sync_with_stdio(false);
}
int main() {
  pair<int, int> v[6];
  for (int i = 0; i < 6; i++) {
    int a, b;
    cin >> a >> b;
    if (a > b)
      v[i] = pair<int, int>(b, a);
    else
      v[i] = pair<int, int>(a, b);
  }
  sort(v, v + 6);
  for (int i = 0; i < 6; i += 2) {
    if (v[i] != v[i + 1]) {
      cout << "no" << endl;
      return 0;
    }
  }
  cout << "yes" << endl;
}
