Getting Started with Python - 02 (Chapter 1, Section 2) Install the Python environment

2. Install the Python environment

Python is an interpreted, cross-platform high-level programming language, which is adopted by more and more people and enterprises because of its easy-to-learn, high-efficiency, and extensible features. Before learning and using Python, you need to install the Python environment first. This section will detail how to install the Python environment.

2.1 Download the Python installer

The Python official website provides Python installation programs for multiple operating systems such as Windows, Mac OS X, and Linux. You can download the corresponding installation programs from https://www.python.org/downloads/ .

There are two main versions of Python: Python 2 and Python 3. Although Python 2 still has many users, the official support for Python 2 has been stopped in 2020, so it is recommended that beginners start learning directly from Python 3.

2.2 Run the installer

After downloading the Python installation program, double-click to run the program, and install it according to the prompts. During the installation process, you need to pay attention to the following points:

  • Select the "Add Python 3.x to PATH" option to add Python to the system environment variables, so that you can run Python directly on the command line.
  • If multiple Python versions coexist, you need to manually configure the environment variables so that the system can find the Python version that needs to be used.

2.3 Verify installation results

After the installation is complete, open the command line tool and enter the "python" command. If the output is similar to the following information, it means that Python is installed successfully:

 
 

scssCopy code

Python

Guess you like

Origin blog.csdn.net/yueyeguzhuo/article/details/129224257