Help, code is not working


#1




I can't figure out why my code is incorrect...I've gone back continuously to check my work and I've been stuck for a couple days. Please tell me how to fix it!


Replace this line with your code. 
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
    new_word[1:len(new_word)]
    print new_word
    
else:
    print 'empty'


#2

the slice you take here:

new_word[1:len(new_word)]

you don't store it anywhere, store it in new_word (in essence updating the variable)


#4

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