#include <iostream>
using namespace std;

int main(){
  int a;
  cin >> a;
  for(int i=0; i < 3; i++){
    if(a%10 == 7){
      cout << "YES\n";
      return 0;
    }
    a = a/10;
  }
  cout << "NO\n";
  return 0;
}