class Solution {
public boolean isPalindrome(int x) {
if(x>Integer.MAX_VALUE)
return false;
String string= String.valueOf(x);
char[] chars = string.toCharArray();
for(int i =0,j=chars.length-1;i<=chars.length/2-1;i++,j--)
if(chars[i]!=chars[j])
return false;
return true;
}
}