Move it on back


I've been going through a couple exercises and my code seems to be okay when I submit it, however, I believe that there is something wrong with my code as it's not doing what it's supposed to. When I type in a word the code simpy prints out the same word in the same way. i.e. not translated to pyglatin. For some reason i've been able to get to the "Ending up" exercise and that's when I realized something's wrong with my code.

any help woud be greatly appreciated.

pyg = 'ay'

original = raw_input('Enter a word:')

if len(original) > 0 and original.isalpha():
    word = original.lower()
    first = word[0]
    new_word = word + first + pyg
    print original
    print 'empty'.


you still print original, if you already want to print the translated (pyglatin) version, print new_word instead


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.