A palindrome number is one that appears the same when read forward and backward. For example, 123 is not a palindrome but 737 is. To find out whether a number is a palindrome, we need to split it into separate digits and convert the unit of the original number to hundred and the hundred to unit.
For example, a pqr number will be called a palindrome number if pqr=rqp. And pqr will be equal to rqp only if the following is true:
p x 100 + q x 10 + r = r x 100 + q x 10 + p
In other words, we will have to multiply the digit in the unit place by 102 to convert it into the hundreds and convert the digit in the hundreds place to unit by multiplying it by 1. If the result matches the original number, it is a palindrome.