stablegradients/pie-gem5-pairs huggingface dataset:
// Slower C++ solution:
//

// author  : Abhishek

//

#include <bits/stdc++.h>



#define ll long long

#define db double

#define deb(x) cout<<#x<<": "<<x<<"\n"

#define all(x) x.begin(),x.end()

#define fo(i, n) for(i=0 ; i<n ; i++)

#define Fo(i, k, n) for(i=k ; i<n ; i++)



using namespace std;



const ll mod = 1000000007;

const ll N = 300005;  // array size

const ll inf = 10000000000000000;





void print(vector<ll> v) {

    ll i;

    fo(i, v.size())cout << v[i] << " ";

    cout << "\n";

}



vector<ll> read(ll n) {

    ll i;

    vector<ll> arr(n, 0);

    fo(i, n)cin >> arr[i];

    return arr;

}



vector<ll> read(ll n, ll k) {

    ll i;

    vector<ll> arr(n + k, 0);

    Fo(i, k, n + k)cin >> arr[i];

    return arr;

}



bool isEven(ll n) {

    return n % 2 == 0;

}



bool isOdd(ll n) {

    return n % 2 != 0;

}





void solve() {

    ll t;

    cin >> (t);

    while (t--) {



        ll i, j, k, n, m, p, q, x, y, a, b, l, r;





    }

}



int main() {



//#ifndef ONLINE_JUDGE

//    freopen("input.txt", "r", stdin);

//    freopen("output.txt", "w", stdout);

//#endif



    ios_base::sync_with_stdio(false);

    cin.tie(NULL);



    ll i, j, k, n, m, p, q, x, y, a, b, l, r;





    cin>>n;



    Fo(i,1,10){

        Fo(j,1,10){

            if(i*j == n){

                cout<<"Yes\n";

                return 0;

            }

        }

    }



    cout<<"No\n";



    return 0;

}






// Faster C++ solution for the same problem (measured speedup: 5.434242236779212x):
#include <stdio.h>



int main(){

	int angka;

	scanf("%d", &angka);

	int count = 0;

	for(int i = 1; i <= 9; i++){

		for(int j = 1; j <= 9; j++){

			if(angka == i * j){

				count++;

			}

		}

	}

	if(count != 0){

		puts("Yes");

	} else{

		puts("No");

	}

	return 0;

}
// Slower C++ solution:
#include<iostream>

using namespace std;

int main()

{

    int a,n,i,flag=0,j;

    cin>>n;

    for(i=1;i<=9;i++)

    {

        for(j=1;j<=9;j++)

        {

            if(i*j==n)

               flag=1;

        }

    }

    if(flag==1)

        cout<<"Yes";

    else

        cout<<"No";



}

// Faster C++ solution for the same problem (measured speedup: 5.298632958920951x):
#include <cstdio>

int main()

{

	int n;

	scanf("%d",&n);

	int flag=1;

	for(int i=1;i<=9;i++)

	{

		if(n%i==0)

		{

			int k=n/i;

			if(k>=1&&k<=9)

			{

				printf("Yes");

				flag=0;

				break;

			}

		}

	}

	if(flag) printf("No");

	return 0;

 }
// Slower C++ solution:
#include <bits/stdc++.h>



using namespace std;



#define ll long long 

#define endl '\n'

#define IOS ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);

#define SIZE 100005



int main()

{

    int a;

    

    cin >> a;

    for(int i = 1; i <= 9; i++)

    {

		if(a%i==0 && a/i>=1 && a/i <= 9) {cout <<"Yes\n";return 0;}

	}

	cout << "No" << endl;

	return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.296258357140779x):
#include <cstdio>

int main()

{

	int n;

	scanf("%d",&n);

	int flag=1;

	for(int i=1;i<=9;i++)

	{

		if(n%i==0)

		{

			int k=n/i;

			if(k>=1&&k<=9)

			{

				printf("Yes");

				flag=0;

				break;

			}

		}

	}

	if(flag) printf("No");

	return 0;

 }
// Slower C++ solution:
#include <iostream>



using namespace std;



int main()

{

    int n=0;

    int x=0;

    cin>>n;

    for(int i=1;i<=9;i++)

    {

        if(x==1)

        {

            break;

        }

        for(int i2=1;i2<=9;i2++)

        {

            if(i*i2==n)

            {

               x++;

               break;

            }

            else

            {

                x=x;

            }

        }

    }

    if(x==1)

    {

        cout<<"Yes";

    }

    else

    {

        cout<<"No";

    }

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.298396476726209x):
#include <cstdio>

int main()

{

	int n;

	scanf("%d",&n);

	int flag=1;

	for(int i=1;i<=9;i++)

	{

		if(n%i==0)

		{

			int k=n/i;

			if(k>=1&&k<=9)

			{

				printf("Yes");

				flag=0;

				break;

			}

		}

	}

	if(flag) printf("No");

	return 0;

 }
// Slower C++ solution:
#include<iostream>

using namespace std;

int main()

{

    int a,n,i,flag=0,j;

    cin>>n;

    for(i=1;i<=9;i++)

    {

        for(j=1;j<=9;j++)

        {

            if(i*j==n)

               flag=1;

        }

    }

    if(flag==1)

        cout<<"Yes";

    else

        cout<<"No";



}

// Faster C++ solution for the same problem (measured speedup: 5.295332319655411x):
#include <stdio.h>







int main (){



    // int num[9] = {1,2,3,4,5,6,7,8,9};

    int input;

    int flag = 0;

    scanf("%d", &input);



    for(int i = 1; i <= 9; i++){

        for (int j = 1; j <= 9 ; j++){

            // int temp = i*j;

            if (input == (i*j)){

                flag = 1;

               break;

            }

        }

    }



    if (flag == 1){

        printf("Yes\n");

    } else {

        printf("No\n");

    }

    return 0;

}
// Slower C++ solution:
#include <bits/stdc++.h>



using namespace std;



#define ll long long 

#define endl '\n'

#define IOS ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);

#define SIZE 100005



int main()

{

    int a;

    

    cin >> a;

    for(int i = 1; i <= 9; i++)

    {

		if(a%i==0 && a/i>=1 && a/i <= 9) {cout <<"Yes\n";return 0;}

	}

	cout << "No" << endl;

	return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.292959197068823x):
#include <stdio.h>







int main (){



    // int num[9] = {1,2,3,4,5,6,7,8,9};

    int input;

    int flag = 0;

    scanf("%d", &input);



    for(int i = 1; i <= 9; i++){

        for (int j = 1; j <= 9 ; j++){

            // int temp = i*j;

            if (input == (i*j)){

                flag = 1;

               break;

            }

        }

    }



    if (flag == 1){

        printf("Yes\n");

    } else {

        printf("No\n");

    }

    return 0;

}
// Slower C++ solution:
#include <iostream>



using namespace std;



int main()

{

    int n=0;

    int x=0;

    cin>>n;

    for(int i=1;i<=9;i++)

    {

        if(x==1)

        {

            break;

        }

        for(int i2=1;i2<=9;i2++)

        {

            if(i*i2==n)

            {

               x++;

               break;

            }

            else

            {

                x=x;

            }

        }

    }

    if(x==1)

    {

        cout<<"Yes";

    }

    else

    {

        cout<<"No";

    }

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.295095984770819x):
#include <stdio.h>







int main (){



    // int num[9] = {1,2,3,4,5,6,7,8,9};

    int input;

    int flag = 0;

    scanf("%d", &input);



    for(int i = 1; i <= 9; i++){

        for (int j = 1; j <= 9 ; j++){

            // int temp = i*j;

            if (input == (i*j)){

                flag = 1;

               break;

            }

        }

    }



    if (flag == 1){

        printf("Yes\n");

    } else {

        printf("No\n");

    }

    return 0;

}
// Slower C++ solution:
#include <iostream>

#include <cstdio>

#include <cstring>

#include <cstdlib>

#include <algorithm>

using namespace std;



int main()

{

    int n;scanf("%d",&n);

    if(n==1||n==2||n==3||n==4||n==5||n==6||n==7||n==8||n==9||n==10||n==12||n==14||n==15||n==16||n==18||n==20||n==21||n==24||n==25||n==27||n==28||n==30||n==32||n==35||n==36||n==40||n==42||n==45||n==48||n==49||n==54||n==56||n==63||n==64||n==72||n==81)

        printf("Yes\n");

    else

        printf("No\n");

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.241812511908099x):
#include <stdio.h>







int main (){



    // int num[9] = {1,2,3,4,5,6,7,8,9};

    int input;

    int flag = 0;

    scanf("%d", &input);



    for(int i = 1; i <= 9; i++){

        for (int j = 1; j <= 9 ; j++){

            // int temp = i*j;

            if (input == (i*j)){

                flag = 1;

               break;

            }

        }

    }



    if (flag == 1){

        printf("Yes\n");

    } else {

        printf("No\n");

    }

    return 0;

}
// Slower C++ solution:
#include <iostream>

#include <cstdio>

#include <cstring>

#include <cstdlib>

#include <algorithm>

using namespace std;



int main()

{

    int n;scanf("%d",&n);

    for(int i=1;i<10;i++)

    {

        for(int j=1;j<10;j++)

        {

            if(i*j==n)

            {

                printf("Yes\n");

                return 0;

            }

        }

    }

    printf("No\n");

    return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.241731842078349x):
#include <stdio.h>







int main (){



    // int num[9] = {1,2,3,4,5,6,7,8,9};

    int input;

    int flag = 0;

    scanf("%d", &input);



    for(int i = 1; i <= 9; i++){

        for (int j = 1; j <= 9 ; j++){

            // int temp = i*j;

            if (input == (i*j)){

                flag = 1;

               break;

            }

        }

    }



    if (flag == 1){

        printf("Yes\n");

    } else {

        printf("No\n");

    }

    return 0;

}
// Slower C++ solution:
//-- In The Name of God --

#include<bits/stdc++.h>

using namespace std;





#define      mod     1e9+7

#define      pai     acos(-1)

#define      ff      first

#define      ss      second

#define      ll      long long

#define      pb      push_back

#define      mp      make_pair

#define      endl    "\n"

#define      fii     freopen("input.txt","r",stdin);

#define      foo     freopen("output.txt","w",stdout);

#define      fast    ios_base::sync_with_stdio(0);cin.tie(NULL);cout.tie(NULL);



const   ll   mx=1e5+100;



int main()

{

    fast;

    ll i,j,a,b,c,d,n,m,t;

    cin>>n;

    ll l=1,r=9;

    if(n%1==0||n%2==0||n%3==0||n%4==0||n%5==0||n%6==0||n%7==0||n%8==0||n%9==0)

    {

        if(n%1==0&&((n/1)>=l&&(n/1)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%2==0&&((n/2)>=l&&(n/2)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%3==0&&((n/3)>=l&&(n/3)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%4==0&&((n/4)>=l&&(n/4)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%5==0&&((n/5)>=l&&(n/5)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%6==0&&((n/6)>=l&&(n/6)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%7==0&&((n/7)>=l&&(n/7)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%8==0&&((n/8)>=l&&(n/8)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%9==0&&((n/9)>=l&&(n/9)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else

        {

            cout<<"No"<<endl;

        }



    }

    else

    {

        cout<<"No"<<endl;

    }

    return 0;

}




// Faster C++ solution for the same problem (measured speedup: 5.373939525431791x):
#include <stdio.h>







int main (){



    // int num[9] = {1,2,3,4,5,6,7,8,9};

    int input;

    int flag = 0;

    scanf("%d", &input);



    for(int i = 1; i <= 9; i++){

        for (int j = 1; j <= 9 ; j++){

            // int temp = i*j;

            if (input == (i*j)){

                flag = 1;

               break;

            }

        }

    }



    if (flag == 1){

        printf("Yes\n");

    } else {

        printf("No\n");

    }

    return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

int main()

{

    int i,n,m=1;

    cin>>n;

    for(i=1;i<=9;i++)

    {

        if(!(n%i)&&(n/i>=1&&n/i<=9))

        {

            puts("Yes");

            m=0;

            break;



        }

    }

    if(m)

        puts("No");

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.240403794948029x):
#include <stdio.h>







int main (){



    // int num[9] = {1,2,3,4,5,6,7,8,9};

    int input;

    int flag = 0;

    scanf("%d", &input);



    for(int i = 1; i <= 9; i++){

        for (int j = 1; j <= 9 ; j++){

            // int temp = i*j;

            if (input == (i*j)){

                flag = 1;

               break;

            }

        }

    }



    if (flag == 1){

        printf("Yes\n");

    } else {

        printf("No\n");

    }

    return 0;

}
// Slower C++ solution:
//----------------------Shanu Garg here---------------------

//-------------Search on youtube : Shanu Garg---------------

//-Studying at National Institute of Technology Delhi(NITD)-

//---------------------From Delhi, India--------------------



#include<bits/stdc++.h>

#include<algorithm>

using namespace std;



#define f(i,n) for(auto i=0;i<n;i++)

#define fr(i,n) for(auto i=n-1;i>=0;i--)

#define fs(i,a,b,c) for(auto i=a;i!=b;i+=c)

#define fl(i,x) for(auto i : x)

#define nl cout<<"\n";

#define chk(x) cout<<#x<<x<<" ", nl

#define ll long long int

#define ull unsigned long long int

#define vi vector<int>

#define vvi vector<vi>

#define pr pair<ll, ll>

#define vii vector<pair<int, int>>

#define vll vector<pr>

#define vl vector<ll>

#define m(a,b) map<a, b>

#define mid(a,b) ((a+b)/2)

#define pb push_back

#define LCM(a,b) ((a*b)/__gcd(x,y))

const int INF = 0x3f3f3f3f, mod = 1e9 + 7;



class triplet{

    ll f, s, t;};



vl in(ll n){vl v;ll x;

    f(i,n)

    cin>>x, v.pb(x);

    return v;}



vll in_pr(ll n){

    vll ar;

    ll x,y;

    f(i,n)

    {cin>>x>>y;

    ar[i]={x,y};

    }

    return ar;

}

void out(vl v, char ch='\0'){

    fl(i,v)

    cout<<i<<ch;

}



void solve(){

    ll N;

    cin>>N;

    bool flag=false;

    for(int i=1;i<10;i++)

    if(N%i == 0)

    if(N/i < 10  &&  N/i > 0)

    flag=true;



    flag ? cout<<"Yes" : cout<<"No";

}



int main(){

    ios_base::sync_with_stdio(false);

    cin.tie(NULL);

    solve();

   return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.40892273378062x):
#include <stdio.h>







int main (){



    // int num[9] = {1,2,3,4,5,6,7,8,9};

    int input;

    int flag = 0;

    scanf("%d", &input);



    for(int i = 1; i <= 9; i++){

        for (int j = 1; j <= 9 ; j++){

            // int temp = i*j;

            if (input == (i*j)){

                flag = 1;

               break;

            }

        }

    }



    if (flag == 1){

        printf("Yes\n");

    } else {

        printf("No\n");

    }

    return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

#define int  long long

#define tc(t)  int t; cin>>t; while(t--)

#define f(n)    for(int i=0;i<n;i++)

#define endl   "\n"

int32_t main()

{

    ios_base::sync_with_stdio(false);

    cin.tie(NULL);

 int n;

 cin>>n;

 if(n==0) cout<<"Yes"<<endl;

 else {

     bool flag=true;

     for (int i = 1; i <= 9; i++) {

         if (n % i == 0) {

             int b=n/i;

             if(b>=1&&b<=9) 

             { flag=false;

                 cout<<"Yes"<<endl;

                 break;

             }



         }



     }

     if(flag) cout<<"No"<<endl;

 }



}

// Faster C++ solution for the same problem (measured speedup: 5.3721964590145985x):
#include <stdio.h>







int main (){



    // int num[9] = {1,2,3,4,5,6,7,8,9};

    int input;

    int flag = 0;

    scanf("%d", &input);



    for(int i = 1; i <= 9; i++){

        for (int j = 1; j <= 9 ; j++){

            // int temp = i*j;

            if (input == (i*j)){

                flag = 1;

               break;

            }

        }

    }



    if (flag == 1){

        printf("Yes\n");

    } else {

        printf("No\n");

    }

    return 0;

}
// Slower C++ solution:
#include<iostream>

using namespace std;

int main()

{

    int a,n,i,flag=0,j;

    cin>>n;

    for(i=1;i<=9;i++)

    {

        for(j=1;j<=9;j++)

        {

            if(i*j==n)

               flag=1;

        }

    }

    if(flag==1)

        cout<<"Yes";

    else

        cout<<"No";



}

// Faster C++ solution for the same problem (measured speedup: 5.313505086371494x):
#include <stdio.h>



int main(){

    int N;

    scanf("%d", &N);

    int temp = 0;

    for(int i = 1; i <= 9; i++){

        if((double)N / i <= 9 && (double)N / i >= 1 && N % i == 0){

            temp = 1;

            break;

        }

    }

    if(temp == 1){

        puts("Yes");

    }else{

        puts("No");

    }

    return 0;

}
// Slower C++ solution:
#include <bits/stdc++.h>



using namespace std;



#define ll long long 

#define endl '\n'

#define IOS ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);

#define SIZE 100005



int main()

{

    int a;

    

    cin >> a;

    for(int i = 1; i <= 9; i++)

    {

		if(a%i==0 && a/i>=1 && a/i <= 9) {cout <<"Yes\n";return 0;}

	}

	cout << "No" << endl;

	return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.311123819592899x):
#include <stdio.h>



int main(){

    int N;

    scanf("%d", &N);

    int temp = 0;

    for(int i = 1; i <= 9; i++){

        if((double)N / i <= 9 && (double)N / i >= 1 && N % i == 0){

            temp = 1;

            break;

        }

    }

    if(temp == 1){

        puts("Yes");

    }else{

        puts("No");

    }

    return 0;

}
// Slower C++ solution:
#include <iostream>



using namespace std;



int main()

{

    int n=0;

    int x=0;

    cin>>n;

    for(int i=1;i<=9;i++)

    {

        if(x==1)

        {

            break;

        }

        for(int i2=1;i2<=9;i2++)

        {

            if(i*i2==n)

            {

               x++;

               break;

            }

            else

            {

                x=x;

            }

        }

    }

    if(x==1)

    {

        cout<<"Yes";

    }

    else

    {

        cout<<"No";

    }

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.313267940421899x):
#include <stdio.h>



int main(){

    int N;

    scanf("%d", &N);

    int temp = 0;

    for(int i = 1; i <= 9; i++){

        if((double)N / i <= 9 && (double)N / i >= 1 && N % i == 0){

            temp = 1;

            break;

        }

    }

    if(temp == 1){

        puts("Yes");

    }else{

        puts("No");

    }

    return 0;

}
// Slower C++ solution:
#include <iostream>

#include <cstdio>

#include <cstring>

#include <cstdlib>

#include <algorithm>

using namespace std;



int main()

{

    int n;scanf("%d",&n);

    if(n==1||n==2||n==3||n==4||n==5||n==6||n==7||n==8||n==9||n==10||n==12||n==14||n==15||n==16||n==18||n==20||n==21||n==24||n==25||n==27||n==28||n==30||n==32||n==35||n==36||n==40||n==42||n==45||n==48||n==49||n==54||n==56||n==63||n==64||n==72||n==81)

        printf("Yes\n");

    else

        printf("No\n");

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.259801606869103x):
#include <stdio.h>



int main(){

    int N;

    scanf("%d", &N);

    int temp = 0;

    for(int i = 1; i <= 9; i++){

        if((double)N / i <= 9 && (double)N / i >= 1 && N % i == 0){

            temp = 1;

            break;

        }

    }

    if(temp == 1){

        puts("Yes");

    }else{

        puts("No");

    }

    return 0;

}
// Slower C++ solution:
#include <iostream>

#include <cstdio>

#include <cstring>

#include <cstdlib>

#include <algorithm>

using namespace std;



int main()

{

    int n;scanf("%d",&n);

    for(int i=1;i<10;i++)

    {

        for(int j=1;j<10;j++)

        {

            if(i*j==n)

            {

                printf("Yes\n");

                return 0;

            }

        }

    }

    printf("No\n");

    return 0;

}

// Faster C++ solution for the same problem (measured speedup: 5.259720660192894x):
#include <stdio.h>



int main(){

    int N;

    scanf("%d", &N);

    int temp = 0;

    for(int i = 1; i <= 9; i++){

        if((double)N / i <= 9 && (double)N / i >= 1 && N % i == 0){

            temp = 1;

            break;

        }

    }

    if(temp == 1){

        puts("Yes");

    }else{

        puts("No");

    }

    return 0;

}
// Slower C++ solution:
//-- In The Name of God --

#include<bits/stdc++.h>

using namespace std;





#define      mod     1e9+7

#define      pai     acos(-1)

#define      ff      first

#define      ss      second

#define      ll      long long

#define      pb      push_back

#define      mp      make_pair

#define      endl    "\n"

#define      fii     freopen("input.txt","r",stdin);

#define      foo     freopen("output.txt","w",stdout);

#define      fast    ios_base::sync_with_stdio(0);cin.tie(NULL);cout.tie(NULL);



const   ll   mx=1e5+100;



int main()

{

    fast;

    ll i,j,a,b,c,d,n,m,t;

    cin>>n;

    ll l=1,r=9;

    if(n%1==0||n%2==0||n%3==0||n%4==0||n%5==0||n%6==0||n%7==0||n%8==0||n%9==0)

    {

        if(n%1==0&&((n/1)>=l&&(n/1)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%2==0&&((n/2)>=l&&(n/2)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%3==0&&((n/3)>=l&&(n/3)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%4==0&&((n/4)>=l&&(n/4)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%5==0&&((n/5)>=l&&(n/5)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%6==0&&((n/6)>=l&&(n/6)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%7==0&&((n/7)>=l&&(n/7)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%8==0&&((n/8)>=l&&(n/8)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else if(n%9==0&&((n/9)>=l&&(n/9)<=r))

        {

            cout<<"Yes"<<endl;

        }

        else

        {

            cout<<"No"<<endl;

        }



    }

    else

    {

        cout<<"No"<<endl;

    }

    return 0;

}




// Faster C++ solution for the same problem (measured speedup: 5.392382059997471x):
#include <stdio.h>



int main(){

    int N;

    scanf("%d", &N);

    int temp = 0;

    for(int i = 1; i <= 9; i++){

        if((double)N / i <= 9 && (double)N / i >= 1 && N % i == 0){

            temp = 1;

            break;

        }

    }

    if(temp == 1){

        puts("Yes");

    }else{

        puts("No");

    }

    return 0;

}
// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;

int main()

{

    int i,n,m=1;

    cin>>n;

    for(i=1;i<=9;i++)

    {

        if(!(n%i)&&(n/i>=1&&n/i<=9))

        {

            puts("Yes");

            m=0;

            break;



        }

    }

    if(m)

        puts("No");

    return 0;

}


// Faster C++ solution for the same problem (measured speedup: 5.258388055408922x):
#include <stdio.h>



int main(){

    int N;

    scanf("%d", &N);

    int temp = 0;

    for(int i = 1; i <= 9; i++){

        if((double)N / i <= 9 && (double)N / i >= 1 && N % i == 0){

            temp = 1;

            break;

        }

    }

    if(temp == 1){

        puts("Yes");

    }else{

        puts("No");

    }

    return 0;

}