How Many Eight Digit Palindromes Are There?
b = 10**7 | |
e = 10**8 | |
count = 0 | |
for i in range(b,e,1): | |
if str(i) == str(i)[::-1]: | |
count += 1 | |
print (count) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment