#include <bits/stdc++.h>
using namespace std;
int hw[1010];
int main(void) {
  for (int i = 0; i < 6; i++) {
    int h, w;
    cin >> h >> w;
    hw[h]++;
    hw[w]++;
  }
  int ans = 0;
  for (int i = 0; i < 1001; i++) {
    if (hw[i] != 0)
      if (hw[i] % 4 == 0) ans += hw[i] / 4;
  }
  if (ans == 3)
    cout << "yes" << endl;
  else
    cout << "no" << endl;
  return 0;
}
