#include <bits/stdc++.h>

typedef long long ll;
using namespace std;

typedef pair<int,int> P;

int main() {
	cin.tie(0);
	ios::sync_with_stdio(false);

	P p[6];
	int h,w;
	for (int i = 0;i < 6;i++){
		cin >> h >> w;
		p[i] = P(min(h,w),max(h,w));
	}
	sort(p,p+6);

	if(p[0] == p[1] && p[2] == p[3] && p[4] == p[5] && p[0].first == p[2].first && p[3].second == p[4].second && p[5].first == p[0].second){
		cout << "yes" << endl;
	}else{
		cout << "no" << endl;
	}

	return 0;

}

