Python3 installation, environment variable configuration, PyCharm new Python project

1. Download the installation package

Pyhton official website download >>The latest stable version of the installation package:

 Find the appropriate version to download:

If the download is slow, here is a stable version of the 3.10.11 installation package:

Link: https://pan.baidu.com/s/16GnWjkGFuSfWfaI9UVX8qA?pwd=4u5o 
Extraction code: 4u5o 

Note: This installation package can be decompressed, no installation program is required!

In the directory after decompression or installation, you can see the corresponding python.exe :

 2. System environment variable configuration

The test environment here: Windows10 operating system

Open in turn: This Computer -> Properties -> System -> Advanced System Design

Then the following schematic diagram appears, and then click " Environment Variables "

Click the " New " button in the system variable to create a new " PYTHON_HOME ", the value is the Python installation and decompression directory, as shown in the following two pictures:

Then find the "Path" variable, click the " Edit " button, and add the variable name of the newly added Python installation and decompression directory, as shown in the following figure:

 At this point, the environment variable configuration is complete.

Verify success:

Open cmd and enter "python --version":

 If the installed version can be output normally, it means that the installation configuration is successful.

3. PyCharm creates a new python project

Open PyCharm, click New Project

 After the creation is complete, there will be a test class, you can run the test:

 operation result:

 At this point, Python programming can be performed. . .

Supongo que te gusta

Origin blog.csdn.net/java_faep/article/details/132231744
Recomendado
Clasificación