#include <bits/stdc++.h>
int palindrome(int n) {
  int res = 0;
  while (n) {
    res = res * 10 + (n % 10);
    n /= 10;
  }
  return res;
}
int main() {
  int n;
  scanf("%d", &n);
  while (n % 10 == 0) n /= 10;
  if (n == palindrome(n))
    printf("YES\n");
  else
    printf("NO\n");
  return 0;
}
