#include <bits/stdc++.h>
const double EPS = 1e-8;
using namespace std;
long long gcd(long long a, long long b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
template <typename A, size_t N, typename T>
void Fill(A (&array)[N], const T &val) {
  std::fill((T *)array, (T *)(array + N), val);
}
class Graph {
 public:
  int vn;
  int sumcost = 0;
  vector<vector<pair<int, int>>> g;
  Graph(int n) {
    vn = n;
    g.resize(n);
  }
  virtual void con(int a, int b, int w) = 0;
  int getWeight(int f, int t) {
    auto itr = lower_bound((g[f]).begin(), (g[f]).end(), make_pair(t, INT_MIN));
    if (itr != g[f].end()) return itr->second;
    return INT_MIN;
  }
  int Costsum() { return sumcost; }
  void scan(int edcount, bool oindexed, bool w) {
    for (int i = (0); (edcount) > i; i++) {
      int a, b, c = 1;
      scanf("%d %d", &a, &b);
      if (w) scanf("%d", &c);
      con(a - oindexed, b - oindexed, c);
    }
  }
};
class BiDGraph : public Graph {
 public:
  BiDGraph(int n) : Graph(n) {}
  void con(int a, int b, int w = 1) {
    g[a].push_back({b, w});
    g[b].push_back({a, w});
    sumcost++;
  }
};
int factorial(int n) {
  if (n > 0) {
    return n * factorial(n - 1);
  } else {
    return 1;
  }
}
int main() {
  map<pair<int, int>, int> al;
  map<int, int> m;
  for (int i = (0); (6) > i; i++) {
    int a, b;
    cin >> a >> b;
    m[a]++;
    m[b]++;
    al[{min(a, b), max(a, b)}]++;
  }
  bool f = 1;
  for (auto itr : al) {
    if (itr.second % 2) f = 0;
  }
  for (auto itr : m) {
    if (itr.second % 4) f = 0;
  }
  cout << (f ? "yes" : "no") << endl;
  return 0;
}
