#include <bits/stdc++.h>
using namespace std;
const int N = 10001;
int arr[N], n;
bool isPal(string s) {
  bool M = 1;
  for (int i = 0, j = s.size() - 1; i < j; i++, j--) {
    if (s[i] != s[j]) M = 0;
  }
  if (M) return 1;
  return 0;
}
string s;
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  cin >> s;
  if (isPal(s)) return cout << "YES" << endl, 0;
  int x = 0;
  for (int i = s.size() - 1; i >= 0; i--) {
    if (s[i] == '0')
      x++;
    else
      break;
  }
  while (x) {
    x--;
    s = "0" + s;
    if (isPal(s)) return cout << "YES" << endl, 0;
  }
  return cout << "NO" << endl, 0;
}
