in Windows 10, How to configure Visual Studio Code to find the Python 3 interpreter?

python, visual-studio-code

Solution

macOS

VSCode -> Preferences -> Settings -> scroll down to Python Configuration.

Click the pencil on the left of the configuration you'd like to use and click Copy Settings.

`"python.pythonPath": "python3.6"`

Problem

In Windows 10, How Visual Studio Code should be configured to find the Python 3 interpreter? Visual Studio Code is not able to find the Python 3 interpreter. I have added the Python extension, the Python extension at https://marketplace.visualstudio.com/items?itemName=donjayamanne.python. How `settings.js` should be changed to use Python? Even if `python.pythonPath` in `settings.js` is changed to be led to `python.exe`, which is at "C:\Users<User>\AppData\Local\Programs\Python\Python36-32\p‌ython.exe", if I select `Python: Select Workspace Interpreter` in the command palette, I get the message `Please open a workspace to select the Python Interpreter`. Why is this happening?

Original source