Problem: 

Input

The only line of the input contains a string of digits. The length of the string is between 1 and 10, inclusive.

Output

Output "Yes" or "No".

Examples

Input

373


Output

Yes


Input

121


Output

No


Input

436


Output

Yes

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
#pragma GCC optimize("O3")
#pragma GCC target("sse4")
const double PI = acos(-1.0);
const long long mod = 1000000007;
const long long INF = 1e9;
const long long LINF = 1e18;
const long long MAXN = 1e5 + 1;
const double EPS = 1e-9;
bool check(string s) {
  for (long long i = (0); i < ((int)((s).size()) / 2); ++i)
    if (s[i] != s[(int)((s).size()) - 1 - i]) return 0;
  return 1;
}
void fake_next(string& s) {
  int h = 10 * (s[0] - '0') + s[1] - '0';
  int m = 10 * (s[3] - '0') + s[4] - '0';
  if (m < 59)
    ++m;
  else {
    m = 0;
    ++h;
    if (h == 24) h = 0;
  }
  string t = to_string(h);
  if ((int)((t).size()) < 2) t = '0' + t;
  t += ':';
  s = to_string(m);
  if ((int)((s).size()) < 2) s = '0' + s;
  s = t + s;
}
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  string s;
  cin >> s;
  string t = s;
  for (long long i = (0); i < ((int)((s).size())); ++i) {
    if (s[i] == '3' || s[i] == '7') continue;
    if (s[i] == '1' || s[i] == '2') {
      cout << "NO";
      return 0;
    }
    if (s[i] == '4')
      s[i] = '6';
    else if (s[i] == '6')
      s[i] = '4';
    else if (s[i] == '5')
      s[i] = '9';
    else if (s[i] == '9')
      s[i] = '5';
    else if (s[i] == '8')
      s[i] = '0';
    else
      s[i] = '8';
  }
  t += s;
  s = t;
  for (long long i = (0); i < ((int)((s).size())); ++i)
    if (s[i] != s[(int)((s).size()) - 1 - i]) {
      cout << "NO";
      return 0;
    }
  cout << "YES";
  return 0;
}