Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def isPalindrome(a,b):
- s = str(a*b)
- if s == s[::-1]:
- return True
- palinlist = []
- for i in range(999, 101, -1):
- for j in range(999, 101, -1):
- num = i*j
- if isPalindrome(i,j):
- palinlist.append(num)
- print(max(palinlist))
Add Comment
Please, Sign In to add comment