程序師世界是廣大編程愛好者互助、分享、學習的平台,程序師世界有你更精彩!
首頁
編程語言
C語言|JAVA編程
Python編程
網頁編程
ASP編程|PHP編程
JSP編程
數據庫知識
MYSQL數據庫|SqlServer數據庫
Oracle數據庫|DB2數據庫
您现在的位置: 程式師世界 >> 編程語言 >  >> 更多編程語言 >> Python

Writing Python programs using vscode

編輯:Python

Catalog

Preface

Software installation

Anaconda To configure

VS Code To configure

The test program


Preface

This article describes how to configure the environment , Use vscode edit python Program .

 

Software installation

This article uses the following two software :

  • Anaconda: https://www.anaconda.com/
  • Visual Studio Code (VS Code): https://code.visualstudio.com/

Anaconda To configure

Omit here Anaconda Installation steps . Pay attention to the following two points during installation :

  1. Don't check “Add Anaconda to my PATH environment variable”. The steps for manually configuring environment variables are detailed below .
  2. Check “Register Anaconda as my default Python 3.8”.

add to Anaconda Go to the environment variable step :

1. stay Win10 Start Menu Mid search “Run”

2. stay Run Mid search “sysdm.cpl”

3. Open the environment variable configuration window

4. stay Path Add Anaconda Installation path for

VS Code To configure

Omit here VS Code Installation steps .

After the installation is completed, please wait Extensions Mid search python, And install python plug-in unit .

 

The test program

Next , Create a test with python Program , Confirm whether the environment is available .

1. Create a new one called “test.py” The file of , And use vs code open .

2. stay vs code Choose... In the lower right corner python Interpreter version

3. stay test.py Write the following “ classic ” Test code

print('Hello World!')

4. Click the run button

5. Confirm operation results


  1. 上一篇文章:
  2. 下一篇文章:
Copyright © 程式師世界 All Rights Reserved