#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  scanf("%d", &n);
  while (n % 10 == 0) {
    n /= 10;
  }
  int rev = 0;
  int tmp = n;
  while (tmp > 0) {
    rev = rev + tmp % 10;
    tmp /= 10;
    if (tmp != 0) rev *= 10;
  }
  if (rev == n) {
    puts("YES");
  } else {
    puts("NO");
  }
}
