word = input ("Input word: ") if word == "hello": s1 = word[:2] s2 = word[2:] word = s1 + s2 + "ay" print word else: print "wrong word"
Результат такой:
Input word: hello
Traceback (most recent call last):
File “python”, line 1, in <module>
File “<string>”, line 1, in <module>
NameError: name ‘hello’ is not defined
В чём ошибка?