Return whether the decimal digits of integer x read the same left-to-right and right-to-left. Negative values are not palindromes.
Input / output
x: integerExamples
121 returns true.-121 and 10 return false.Constraints
-2,147,483,648 <= x <= 2,147,483,647Follow-up Can you reverse only half the digits to avoid strings and integer overflow?