// Created by abhay
#include <bits/stdc++.h>
#define sz(a) int((a).size())
#define pb push_back
#define allc c.begin(),c.end()
#define tr(c,i) for(typeof(c).begin() i = c.begin(); i != c.end(); i++)
#define present(c,x) (c.find(x) != c.end())
#define cpresent(c,x) (find(allc,x) != c.end())
#define rep(i,n) for(int i=0;i<(n);i++)
#define ll long long
using namespace std;

int main()

{
	ios::sync_with_stdio(0);
	cin.tie(0);
	cout.tie(0);
	ll n;
	cin>>n;
	while(n)
	{
	    int r=n%10;
	    if(r==7)
	        {
	            cout<<"YES"<<endl;
	            return 0;
	        }
	   n=n/10;
	}
	cout<<"NO"<<endl;
  return 0;
}
