#include <algorithm>

#include <cassert>
#include <chrono>
#include <cmath>
#include <complex>
#include <cstdint>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <limits>
#include <list>
#include <map>
#include <queue>
#include <random>
#include <regex>
#include <set>
#include <stack>
#include <string>
#include <tuple>
#include <utility>
#include <vector>
using namespace std;
using ll = long long;
using ld = long double;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
using vll = vector<ll>;
using vvll = vector<vector<ll>>;
using vvvll = vector<vector<vector<ll>>>;
using vii = vector<int>;
using vvii = vector<vector<int>>;
using vvvii = vector<vector<vector<int>>>;
using vdd = vector<double>;
using vvdd = vector<vector<double>>;
using vvvdd = vector<vector<vector<double>>>;
#define pb push_back
#define mp make_pair
#define sc second
#define fr first
#define endl '\n'
#define stpr std::fixed << setprecision
#define cYES cout << "YES" << endl
#define cNO cout << "NO" << endl
#define cYes cout << "Yes" << endl
#define cNo cout << "No" << endl
#define rep(i, n) for (ll i = 0; i < (n); ++i)
#define drep(i, a, b, d) for (ll i = (a); i <= (b); i += d)
#define Rep(i, a, b) for (ll i = (a); i < (b); ++i)
#define rrep(i, n) for (ll i = n - 1; i >= 0; i--)
#define drrep(i, a, b, d) for (ll i = (a); i >= (b); i -= d)
#define rRep(i, a, b) for (ll i = a; i >= b; i--)
#define crep(i) for (char i = 'a'; i <= 'z'; ++i)
#define Crep(i) for (char i = 'A'; i <= 'Z'; ++i)
#define ALL(x) (x).begin(), (x).end()
ll gcd(ll a, ll b) { return (b == 0 ? a : gcd(b, a % b)); }
ll lcm(ll a, ll b) { return a * b / gcd(a, b); }
constexpr ll MOD = 1000000007;
constexpr ll INF = 1000000011;
constexpr ll MOD2 = 998244353;
constexpr ll LINF = 1001002003004005006ll;
constexpr ld EPS = 10e-10;
template <class T, class U>
inline bool chmax(T &lhs, const U &rhs) {
  if (lhs < rhs) {
    lhs = rhs;
    return 1;
  }
  return 0;
}
template <class T, class U>
inline bool chmin(T &lhs, const U &rhs) {
  if (lhs > rhs) {
    lhs = rhs;
    return 1;
  }
  return 0;
}
template <typename T, typename U>
istream &operator>>(istream &is, pair<T, U> &p) {
  is >> p.first;
  is >> p.second;
  return is;
}
template <typename T>
istream &operator>>(istream &is, vector<T> &v) {
  for (auto &&x : v) is >> x;
  return is;
}
template <typename T, typename U>
ostream &operator<<(ostream &os, const pair<T, U> &p) {
  os << p.first << ' ' << p.second;
  return os;
}
template <class T>
ostream &operator<<(ostream &os, vector<T> &v) {
  for (auto i = begin(v); i != end(v); ++i) {
    if (i != begin(v)) os << ' ';
    os << *i;
  }
  return os;
}

int main(){
    string n,n2;
    cin >> n;
    ll l;
    l=n.size();
    if(n=="0"){cYes;}
    else{
        while(n.substr(l-1,1)=="0"){
            n=n.substr(0,l-1);
            l-=1;
        }
        rep(i,l){
            n2=n.substr(i,1) + n2;
        }
        if(n==n2){cYes;}
        else{cNo;}
    }    
    return 0;
}
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define rep(i,n) for(int i=0;i<n;i++)

int main(){
  string s;
  cin>>s;
  int len=s.length();
  
  while(1){
    if(s[len-1]=='0'){
      s=s.substr(0,len-1);
      len--;
      continue;
    }
    break;
  }
  //cout<<s<<endl;
  
  rep(i,len){
    if(s[i]==s[len-1-i]) continue;
    cout<<"No"<<endl;
    return 0;
  }
  cout<<"Yes"<<endl;
  return 0;
  return 0;
}
