#include <iostream>

using namespace std;

int main()
{
	const int DATASETS = 10000;

	int c1[DATASETS], c2[DATASETS], c3[DATASETS], c = 0;

	while (cin >> c1[c] >> c2[c] >> c3[c])
	{
		c++;
	}

	for (int i = 0; i < c; i++)
	{
		if (c1[i] + c2[i] + (55 - c1[i] - c2[i] - c3[i]) / 7.0 <= 20)
		{
			cout << "YES" << endl;
		}
		else
		{
			cout << "NO" << endl;
		}
	}

	return 0;
}