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;
inline int getint() {
  int f = 1, x = 0;
  char c = getchar();
  while (!isdigit(c)) {
    if (c == '-') f = -1;
    c = getchar();
  }
  while (isdigit(c)) {
    x = x * 10 + c - '0';
    c = getchar();
  }
  return x * f;
}
inline long long getll() {
  long long f = 1, x = 0;
  char c = getchar();
  while (!isdigit(c)) {
    if (c == '-') f = -1;
    c = getchar();
  }
  while (isdigit(c)) {
    x = x * 10 + c - '0';
    c = getchar();
  }
  return x * f;
}
string a;
int main() {
  cin >> a;
  int len = a.size();
  for (int l = 0, r = len - 1; l <= r; ++l, --r) {
    if (a[l] == '1' || a[l] == '2') return printf("No"), 0;
    if (a[l] == '3' && a[r] != '3') return printf("No"), 0;
    if (a[l] == '4' && a[r] != '6') return printf("No"), 0;
    if (a[l] == '5' && a[r] != '9') return printf("No"), 0;
    if (a[l] == '6' && a[r] != '4') return printf("No"), 0;
    if (a[l] == '7' && a[r] != '7') return printf("No"), 0;
    if (a[l] == '8' && a[r] != '0') return printf("No"), 0;
    if (a[l] == '9' && a[r] != '5') return printf("No"), 0;
    if (a[l] == '0' && a[r] != '8') return printf("No"), 0;
  }
  if (len % 2 && a[len / 2] != '3' && a[len / 2] != '7') return printf("No"), 0;
  return printf("Yes"), 0;
  return 0;
}