Python Forum

Full Version: Python would not run after installation
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have just installed Python 3.8.1 (Windows 10, 64 bit) on my computer. Apparently it installed correctly and it shows in the list of programs, when I click on Start in the bottom left corner of the screen.
But when I click on IDLE (Python 3.8 64-bit) and I type ‘Python’ to launch the program, I get the following error message:

NameError: name 'python' is not defined

I am not sure about what I am doing wrong.
Thanks for your help.
You likely didn't add python to your path when you installed it. It's a box to check. You can add still. I don't remember specifics but it's a common problem. Just google "add python to path" and you'll find lots of step by steps. OR you could uninstall it an make sure to check the box this time. All the same.
(Jan-02-2020, 02:57 AM)michael1789 Wrote: [ -> ]You likely didn't add python to your path when you installed it. It's a box to check. You can add still. I don't remember specifics but it's a common problem. Just google "add python to path" and you'll find lots of step by steps. OR you could uninstall it an make sure to check the box this time. All the same.

Thanks for your reply. I checked the box about the path, when I installed the software. Actually after installing the software for the first time, I removed it, because it was not working, and I re-installed it. And I checked the box also the second time.
(Jan-02-2020, 01:53 AM)Charles37 Wrote: [ -> ]But when I click on IDLE (Python 3.8 64-bit) and I type ‘Python’ to launch the program, I get the following error message:

NameError: name 'python' is not defined

The error is maybe from you typing "Python" in the terminal. If you have a window called "Python 3.8.1 SHELL", go there, click the menu: FILE -> NEW FILE

Write your code there, save it as a .py
I was able to write a couple of lines of code and save them in the window called "Python 3.8.1 SHELL"
I assume that the software has been installed properly.
Thanks to All