#include <iostream>
#include <vector>
#include <string>
using namespace std;

int main() {
	int c1,c2,c3;
	vector<string> r;
	while (cin >> c1 >> c2 >> c3)
	{
		if ((55 - c1 - c2 - c3 + 6) / 7 + c1 + c2 > 20)
		{
			r.push_back("NO");
		} else {
			r.push_back("YES");
		}
	}
	for (int i=0; i<r.size(); i++)
	{
		cout << r[i] << endl;
	}
	return 0;
}