What am I doing wrong?


#1


I am stuck in ending UP and i don't know what to do anymore.

It says this when i try to put any word in it. (In this case i put asdf.
Oops, try again. It looks like new_word contains "asdfaay" instead of "sdfaay"!

This is the 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(first)]
    print new_word
else:
    print 'empty'


Please help is appreciated


#2

hint**
mentioned in instruction
You have to assign new_word to new_word[1: len(new_word)]


#3

Thanks, I just found out how to do it. :smiley:


#4

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