how to make a palindrome in python