#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int a, b, c, d, t, n, i, j, ok = 0;
  cin >> a;
  for (i = 0; i <= 9; i++) {
    for (j = 0; j <= 9; j++) {
      if (i * j == a) {
        ok = 1;
      }
    }
  }
  if (ok == 1) {
    cout << "YES"
         << "\n";
  } else {
    cout << "NO"
         << "\n";
  }
}
