Python not found...?

Hey there, I am not new to Python. But, I just stopped coding for a few months. Then I decided to uninstall Python from my device.

After a while, I decided to resume my coding journey… But when I installed Python again and opened VS Code I saw this:

I don’t understand why I see this :thinking:. Please help me sort out this mess.

Thanks in advance!! :grin:

Did you solve this problem?

A simple but effective way to check if python is correctly installed is:

  1. Click on WIN key
  2. write: CMD. A black terminal will open
  3. write: python
    only the word ‘python’ … don’t include the ‘’
  4. if python is correctly installed, you will see the version.
  5. if python is not found, do 2 things.
    ------ 5.1 uninstall python and install it with right click and execute as Admin.
    ------ 5.2 when installing again, double check that you ADD THE PATH. It’s on the first page of the installation process.
  6. Once install is complete, go back to step 1.

Hope this helps

ok…Python is installed. I see the problem now.

Whenever you want to run a python script, always start like this:

python fizz_buzz.py

Write ‘python’ first and then the name of the file to execute (python without the ‘’)

Let me know if that worked.

It worked :innocent:! I don’t know how? It didn’t work yesterday tho…

Thanks, @NicolasATC for your patience and help.

1 Like

Great to know it’s working now! :grinning:

in VS code sometimes this happens to me too. I’ve realized that the file path is not correct, so I have to navigate to the correct path… which is weird, but it has happened.

There is another way to execute python code and it’s thru the command itself. In Windows, using the Windows explorer, navigate to where the python file is and then at the top (where you see the path) make a click and the whole path will become blue. There you write: ‘CMD’ without the ‘’. The command terminal will show up in the correct path. So, you just write: python file.py and the file will open using python. To avoid writing ‘python file.py’ everytime you need to run your code, just press the up arrow, and the historic of commands will be there. I hope this makes sense.

In this video, at 00:47, it’s shown: Windows 10 How to Open Command Prompt in Current Folder or Directory - YouTube

I’m glad I could help you… keep coding!