#include <algorithm>
#include <cstdlib>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
typedef long long LL;

int main() {
  string S; cin >> S;
  int l = 0, r = S.size() - 1;
  bool is_zero = true;
  while (l < r) {
    if (S[l] == S[r]) {
      ++l, --r;
      if (S[l] != '0') is_zero = false;
    } else {
      if (is_zero && S[r] == '0') {
        --r;
      } else {
        cout << "No" << endl;
        return 0;
      }
    }
  }
  cout << "Yes" << endl;
  return 0;
}

#include <bits/stdc++.h>
using namespace std;
#define FOR(a, c) for (int(a) = 0; (a) < (c); (a)++) 
#define FORL(a, b, c) for (int(a) = (b); (a) <= (c); (a)++) 
#define FORR(a, b, c) for (int(a) = (b); (a) >= (c); (a)--) 
#define INF 1000000000000000003 
#define MOD 1000000007
#define F first 
#define S second 
#define PB push_back 
#define POB pop_back 
#define MP make_pair
typedef long long int ll; 
typedef vector<int> vi; 
typedef pair<int, int> pi;
typedef vector<pi>vp;
typedef vector<ll> vl;

int intToBinary (int n) {
    string s = bitset< 32 >( n ).to_string();
    return stoi(s);
}

vector<bool> primeSeive(ll n){
    vector<bool> v(n,true);
    v[0]=false;
    v[1]=false;
    for(ll i=2;i<=sqrt(n);i++){
        for(ll j=i*2;j<=n;j+=i){
            v[j]=false;
        }
    }
    return v;
}

vector<ll> cumSum(vector<ll> arr, int n){
    vector<ll> sumArr;
    sumArr.PB(0);
    ll sum = 0;
    FOR(i,n){
        sum+=arr[i];
        sumArr.PB(sum);
    }
    return sumArr;
}

bool checkPrime(ll num){
    for(int i = 2;i<=sqrt(num);i++){
        if(num%i == 0) return false;
    }
    return true;
}

ll totalSum(vl v){
    ll total = 0;
    FOR(i,v.size()) total += v[i];
    return total;
}

vector<ll> countDivisors(ll n) {
    vector<ll> v(n+1, 1);
    v[0]= 0;
    
    for(ll i= 2; i <= n; i++) {
        for(ll j= i; j <=n; j+=i) {
            v[j]++;
        }
    }
    return v;
}

int main() {
	// your code goes here
	ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    
    string s;
    cin >> s;
    
    if(s[0] == s[1] && s[1] == s[2] ) cout << "Won";
    else cout << "Lost";
    
	return 0;
}
