#include <bits/stdc++.h>
using namespace std;
int main() {
  int x, c = 0, v = 0, i, p = 0;
  int mas[1000];
  cin >> x;
  while (x % 10 == 0) {
    x = x / 10;
  }
  c = x;
  while (x != 0) {
    x = x / 10;
    v++;
  }
  for (i = 0; i < v; i++) {
    mas[i] = c % 10;
    c = c / 10;
  }
  for (i = 0; i < v / 2; i++) {
    if (mas[i] == mas[v - i - 1]) p++;
  }
  if (p == (v / 2))
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
