#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, flag = 1;
  cin >> n;
  while (n % 10 == 0) n /= 10;
  string s = to_string(n);
  for (int i = 0, j = s.length() - 1; i <= j; i++, j--) {
    if (s[i] != s[j]) {
      flag = 0;
      break;
    }
  }
  if (flag)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
  return 0;
}
