Python keeps giving me the following error code:
" File "python", line 10
new_word = [1:len(new_word)]
SyntaxError: invalid syntax"
The 'roof' icon (Don't know what it is called in English) is located underneath the colon, as if it is referring to the colon not belonging there.
I have no clue what I'm doing wrong, any help is welcome!
Thanks in advance!
pyg = 'ay' original = raw_input('Enter a word:') if len(original) > 0 and original.isalpha(): word = original.lower() first = word new_word = word + first + pyg new_word = [1:len(new_word)] print new_word else: print 'empty'