I think you're in python 2.7, that's the reason you're seeing the error.
So here is the detail:
Python 2.7.12 (default, Dec 4 2017, 14:50:18)
[GCC 5.4.0 20160609] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> input('Enter your name please: ')
Enter your name please: hi
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "<string>", line 1, in <module>
NameError: name 'hi' is not defined
However, if you make sure to quote your input while typing, this works.
>>> input('Enter your name please: ')
Enter your name please: "My name is"
'My name is'
>>>
This is the same console and now it works fine. This is the expected behaviour of python2. However if you do the same in the python3, it works fine.
Python 3.5.2 (default, Nov 23 2017, 16:37:01)
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> input('Enter your name please: ')
Enter your name please: hi
'hi'
>>>
You don't need to quote the string input in python3. So you need to quote your string in your input response.