#include <bits/stdc++.h>
using namespace std;
string num2str(int i) {
  stringstream ss;
  ss << i;
  return ss.str();
}
int main() {
  int x;
  cin >> x;
  string s = num2str(x);
  bool lz = true;
  bool ret = true;
  int k = s.size() - 1;
  while (s[k] == '0') k--;
  int i = 0;
  while (s[i] == '0') i++;
  while (i < k) {
    if (s[i] != s[k]) ret = false;
    i++;
    k--;
  }
  if (ret)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
  return 0;
}
