#include "bits/stdc++.h"
using namespace std;
typedef long long ll;
typedef vector<ll> V;
typedef pair<ll,ll> P;
typedef map<ll,ll> M;

#define REP(i,n) for(ll (i) = 0; (i) < (n); ++(i))


int main(){
    V h(6);
    V w(6);
    map<P,ll> m;
    REP(i,6){
        cin >> h[i] >> w[i];
        if(h[i] > w[i])swap(h[i], w[i]);
        m[make_pair(h[i],w[i])]++;
    }
    bool flag = true;
    for(auto x : m){
        if(x.second % 2)
            flag = false;
    }
    if(!flag){
        cout << "no" << endl;
        return 0;
    }
    vector<P> p;
    for(auto x : m){
        REP(i, x.second / 2)
            p.push_back(x.first);
    }
    sort(p.begin(), p.end());

    flag = (
                p[0].first == p[1].first &&
                min(p[0].second, p[1].second) == p[2].first &&
                max(p[0].second, p[1].second) == p[2].second
            );

    cout << (flag ? "yes" : "no" ) << endl;
}

