- Download VSC from https://code.visualstudio.com/ - Run the installer - Start "Visual Studio Code" (VSC), and install the following extensions (Ctrl + Shift + X): > Python: includes Pylance, Python Debugger, Python Environments > Python Extension Pack > Python Debugger > Python Snippets 3 > Pylance > Black Formatter > Jupyter > Docs View - In order to use the local Python environment, go through the following steps: > Open the VSC Settings (Ctrl + ,) > Search for "Python: Python Locator" > Change from "native" to "js" > Re-start VS Code Then you should be able to execute your .PY- and your .IPYNB-files If you cannot run your code, type Ctrl + Shift + P, and select "Python: Select Interpreter". Then select the Python interpreter you want to use. - In order to activate the formatting package "Black" for all my Python files, and to automatically apply the formatting on save, go through the following steps: > View -> Command Palette (Ctrl + Shift + P) > Search for "Preferences: Open User Settings (JSON)" > Adjust your setting.json file. For comparison, mine looks as follows: { "workbench.colorTheme": "Quiet Light", "python.defaultInterpreterPath": "C:\\Programs\\WPy64-31241\\python-3.12.4.amd64\\python.exe", "security.workspace.trust.untrustedFiles": "open", "python.locator": "js", "[python]": { "editor.defaultFormatter": "ms-python.black-formatter", "editor.formatOnSave": true } } - In order to add Snippets, go through the following steps: > View -> Command Palette (Ctrl + Shift + P) > Search for "Snippets: Configure Snippets" > Add a new file [yourName]-snippets, and add the following content: > "Python header": { "scope": "", "prefix": "py_head", "body": [ "\"\"\" ${1:header} \"\"\"" "" "# author: Thomas Haslwanter" "# date: $CURRENT_YEAR-$CURRENT_MONTH-$CURRENT_DATE" "" "# Import standard packages" "import numpy as np" "import matplotlib.pyplot as plt" "import pandas as pd" "from scipy import signal" "" "if __name__ == '__main__':" " ${0:main part of your code}" ], "description": "Header for Python scripts" } - In order to get into "Interactive Mode", you have to open a .py file, and then click on "Run Cell" above a function or code block. Code blocks are indicated with "# %%" at the beginning of a line. This will open a newtab "Interactive", where you can see the results of your code.