Time limit: 0.5s
Memory limit: 16MB
You are given and non-negative integers. Find for each of the integers if they are palindrome or not.
An integer is palindrome if its writing from left to right is the same as its writing from right to left. For example, the numbers , , and are palindromes, but numbers , , or are not palindromes.
The first line of the input will contain , the number of integers we will have to check. The next lines will contain the numbers for which we will have to check if they are palindromes or not.
The line will have
YES if the value is a palindrome or
Constraints and clarifications
- The integers will be less or equal to .
- For tests worth points, the integers will be less or equal to .
5 401 54345 99 102919201 58353
NO YES YES YES NO
The right to left writings for the given numbers are , , , and .