I was following a small tutorial. I did everything exactly as indicated in the tutorial and gave me a variable definition error whereas in the tutorial it did not work.
Can someone explain the error?
Code:
print "hello wolrd"
myName = input("what is your name?")
myVar = "hello"
print (myName)
print (myVar)
Output:
C:\Users\Miguel\Desktop>python poop.py hello wolrd what is your name?Miguel Traceback (most recent call last): File "poop.py", line 2, in <module> myName = input("what is your name?") File "<string">, line 1, in <module> NameError: name 'Miguel' is not defined
The issue is that in the tutorial when I put the name Miguel was supposed to respond with Hello and is not giving, can someone explain me sff?