def is_palindrome(n): return numbers.reverse(n) == n
def test_reversed_integer(self): self.assertEqual(1, numbers.reverse(1)) self.assertEqual(7, numbers.reverse(7)) self.assertEqual(21, numbers.reverse(12)) self.assertEqual(12345, numbers.reverse(54321))