Skip to content

Commit d26f0b2

Browse files
authored
140ms
1 parent 1dc03bc commit d26f0b2

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
class Solution(object):
2+
def isPalindrome(self, x):
3+
a = cmp(x,0)
4+
s = a*x
5+
y = int(`s`[::-1])
6+
return (x == y)

0 commit comments

Comments
 (0)