Break it down


Traceback (most recent call last):
File "python", line 1, in
File "", line 1, in
NameError: name 'wowza' is not defined

What am i doing wrong?

word = input ("Enter a 5 letter word: ")
if len(word) == 5 :
    print str[1:4] + str[0] + "ay"
else :
    print "You have entered an invalid word!"


For the "NameError" as pointed to on line 1, this is because python2 is used for this course and you are implemeting that of python 3. Use raw_input() instead. Also, check your line 3... :wink:


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