#include <bits/stdc++.h>
using namespace std;
int n, m, k, chk[100010];
queue<int> q;
int main() {
  ios::sync_with_stdio(false);
  cin >> n;
  while (n % 10 == 0) n /= 10;
  m = n;
  while (m) {
    k *= 10;
    k += m % 10;
    m /= 10;
  }
  if (k == n)
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
