Step 1. Open Visual Studio Code
Если у вас не установлена
Visual Studio Code нужно
установить Visual Studio Code ...
Открываем
Visual Studio Code
Step 2. Create a new folder my_python_project1 on disk D: and in the Visual Studio Code select this folder
Создаем новую папку my_python_project1 на диске D: и
в Visual Studio Code нажимаем
File → Open Folder ...
и выбираем эту папку D:/my_python_project1
Step 3. Create a new file main.py inside Visual Studio Code
Добавим код в
file D:/My/my.html
print("Hello, world!")
Save the file for this click File → Save
Step 4. Run the project in the debugger to do this click Run → Start Debugging (key F5)
Выбираем "Python File" (то есть запустить текущий Python файл)
Увидим что текст "Hello, world!" отобразился внизу
На заметку 1. Создаем launch.json (выбираем путь к запускаемому файлу)
В параметре program write the path to the file to be launched у меня это файл main.py
На заметку 2. Если нету, то установим Python debugger
На заметку 3. We set stopping points (Breakpoints)
Let's put breakpoints in the file main.py
Breakpoints are set by pressing a key F9
Run the project in the debugger to do this click Run → Start Debugging (key F5) и увидим значения переменных
Скачать пример
D:/my_react_example1
main.py
.vscode
launch.json файл настройки для Visual Studio Code (путь к запускаемому файлу)
Как запустить пример?
1) Открываем Visual Studio Code
2) В Visual Studio Code нажимаем в меню File → Open Folder выбираем папку где распокавали проект
3) Click Run → Run Debugging или кнопку F5