#include <bits/stdc++.h>
using namespace std;
bool is_balan(string n) {
  int i = 0;
  int j = n.size() - 1;
  bool ch;
  for (i; i < (n.size()) / 2; i++) {
    if (n[i] == n[j])
      ch = true;
    else {
      return false;
    }
    j--;
  }
  if (ch) return true;
}
int main() {
  int x;
  cin >> x;
  stringstream ss;
  ss << x;
  string str = ss.str();
  int i = str.size() - 1;
  string str2 = "";
  for (i; i > 0; i--) {
    if (str[i] == '0')
      str2 += "0";
    else
      break;
  }
  for (int j = 0; j < str.size(); i++) {
    if (str[j] == '0')
      str += "0";
    else
      break;
  }
  str2 += str;
  if (str.size() == 1)
    cout << "YES";
  else {
    if (is_balan(str2))
      cout << "YES";
    else {
      cout << "NO";
    }
  }
  return 0;
}
