        #include <iostream>
        using namespace std;
         
        int main()
        {
          int n;
          for(i=1;i<10;i++)
          {
            if(n%i==0){
    		if(n/i<=9 and n/i>0)
              cout<<"YES"<<endl;
            else
              cout<<"NO"<<endl;}
          }
          return 0;
          
          
        }