# Arup Guha
# 7/11/2012
# Reverses a string and checks if the original was a palindrome.

def main():

    ans = "yes"

    # Let's the user do multiple words.
    while ans == "yes":

        mystr = input("enter a word.\n")

        # Reverse the string by concatenating each letter from the end.
        rev = ""
        for i in range(len(mystr)):
            rev = rev + mystr[-(i+1)]

        # This is the definition of a palindrome.
        if rev == mystr:
            print("your word is a palindrome!")
        else:
            print("your word is not a palindrome.")

        # Reprompt for another word.
        ans = input("Would you like to reverse another word?\n")

main()
