#include<iostream>
using namespace std;

int main()
{
	int c1, c2, c3;
	int n, max;

	while (cin>>c1>>c2>>c3) {
		n = 15-c1-c2;
		max = n;
		if (n>c1) max--;
		if (n>c2) max--;
		if (n>c3) max--;
 		if ( (double)max / 7.0 >= 0.5 ) cout<<"YES"<<endl;
		else cout<<"NO"<<endl;
	}

	return 0;
}