Let quasi-palindromic number be such number that adding some leading zeros (possible none) to it produces a palindromic string. 

String t is called a palindrome, if it reads the same from left to right and from right to left.

For example, numbers 131 and 2010200 are quasi-palindromic, they can be transformed to strings "131" and "002010200", respectively, which are palindromes.

You are given some integer number x. Check if it's a quasi-palindromic number.


-----Input-----

The first line contains one integer number x (1 ≤ x ≤ 10^9). This number is given without any leading zeroes.


-----Output-----

Print "YES" if number x is quasi-palindromic. Otherwise, print "NO" (without quotes).


-----Examples-----
Input
131

Output
YES

Input
320

Output
NO

Input
2010200

Output
YES

Difficulty: interview

Starter code:

Solutions:
n = input()
n = n.strip('0')
print('YES' if n == n[::-1] else 'NO')


a = input()
for i in range(11):
    s = '0' * i + a
    if s == s[::-1]:
        print("YES")
        break
else:
    print("NO")


s = input()
i = len(s)-1
while s[i] =='0':
    i-=1
s = s[:(i+1)]
for i in range(len(s)//2):
    if s[i] != s[len(s)-i-1]:
        print('NO')
        return
print('YES')

S = input().strip().strip('0')
print(["NO", "YES"][S == S[::-1]])

n=input()
while(n[-1]=='0'):
    n=n[:-1]
if(n==n[::-1]):
    print("YES")
else:
    print("NO")

n = int(input())

while n % 10 == 0:
  n //= 10

if str(n) == str(n)[::-1]:
  print('YES')
else:
  print('NO')


x = int(input())
while x % 10 == 0:
    x //= 10
x = str(x)
if x == x[::-1]:
    print('YES')
else:
    print('NO')

s=input()
n=10
while(n and s!=s[::-1]):
    s='0'+s
    n-=1
if n==0:
    print("NO")
else:
    print("YES")

n = input()
n = n.strip('0')
a = n[:]
n = n[::-1]

if n == a:
    print("YES")
else:
    print("NO")



s = input().rstrip('0')
print("YES" if s == s[::-1] else "NO")


n = int(input())
while (n % 10 == 0):
    n //= 10
n = str(n)
ans = "YES"
for i in range(len(n) // 2 + 1):
    if (n[i] != n[len(n) - i - 1]):
        ans = "NO"
print(ans)


def solve():

    n = input()

    i = 0
    while n[-i-1] == '0':
        n = '0' + n
        i += 1
    #print(n)

    for i in range(len(n)//2):
        if n[i] != n[-i-1]:
            return "NO"
    return "YES"

print(solve())


s = input()

j = len(s) - 1
i = 0
while s[j] == '0' :
	j-=1
	if s[i] == '0':
		i-=1

res = True
for x in range(i,j+1):
	if s[x] != s[j-x]:
		res = False
		break

print("YES" if res else "NO")

import re
x = re.sub(r'0*$', '', input())
if x == x[::-1]:
    print('YES')
else:
    print('NO')



N = input()
L = len(N)

i = 0
while i < L and N[i] == '0':
  i += 1
j = L-1
while j >= 0 and N[j] == '0':
  j -= 1

if i > L-j-1:
  print('NO')
  return

while i < j:
  if N[i] != N[j]:
    print('NO')
    return
  i += 1
  j -= 1

print('YES')


x = int(input())
while x % 10 == 0:
    x //= 10

b = []
while x > 0:
    b.append(x % 10)
    x //= 10

pol = True
for i in range(len(b) // 2):
    if b[i] != b[len(b) - i - 1]:
        pol = False
        break
if pol:
    print("YES")
else:
    print("NO")

x = int(input())

while x % 10 == 0:
    x //= 10

if list(str(x)) == list(reversed(str(x))):
    print('YES')
else:
    print('NO')


x=input()
for i in range(len(x)):
	#print(i)
	count=len(x)-i-1
	if x[len(x)-i-1]!='0':
		break
#print(count)
x=x[:count+1]
if x==x[::-1]:
	print('YES')
else:
	print('NO')

def ispal(s):
    if s==s[::-1]:
        return True
    else:
        return False
s=str(input())
if ispal(list(s)):
    print("YES")
    return
l=list(s)
while l[-1]=='0':
    l=l[:-1]
if ispal(l):
    print("YES")
else:
    print("NO")

#!/usr/bin/env python3
# encoding: utf-8



#----------
# Constants
#----------



#----------
# Functions
#----------

# Reads a string from stdin, splits it by space chars, converts each
# substring to int, adds it to a list and returns the list as a result.
def get_ints():
    return [ int(n) for n in input().split() ]


# Reads a string from stdin, splits it by space chars, converts each substring
# to floating point numbber, adds it to a list and returns the list as a result.
def get_floats():
    return [ float(n) for n in input().split() ]


#----------
# Execution start point
#----------

def __starting_point():
    a = get_ints()
    assert len(a) == 1
    x = a[0]

    s = str(x).rstrip('0')
    print("YES" if s == s[::-1] else "NO")

__starting_point()

s=input().strip('0')
print('YES' if all(s[i]==s[-1-i] for i in range(len(s))) else 'NO')


s = input().strip()
s1 = str(''.join(list(reversed(s))))
while len(s1) < 100 and s1 != s:
    s1 += '0'
    s = '0' + s
if s == s1:
    print("YES")
else:
    print("NO")

def is_pal(s):
    return s == s[::-1]

s = input()
i = int(s)
j = 0
while i % 10 == 0:
    j += 1
    i /= 10

s = str(int(i))
if is_pal(s):
    print('YES')
else:
    print('NO')