Home  >  Article  >  Backend Development  >  What are the ways to execute python source program?

What are the ways to execute python source program?

hzc
hzcOriginal
2020-07-03 13:37:4411519browse

The ways to execute the python source program are: 1. Enter ipython or ipython3 on the command line to enter the interactive shell environment; 2. Enter python [official shell] on the command line window; 3. Integrated development environment, PyCharm Similar to IDEA.

What are the ways to execute python source program?

#1. The Python source program is a text file in a special format. You can use any text editor software to develop python. The file extension of python is. py

2. Three ways to execute python programs

Interpreter: Use command line input: For example, enter python D:/Code/Python/Hello.py

 python Interpreter: Cpython, pypy, etc.

Interactive: so-called interactive: run the interpreter directly in the terminal command without entering the file name to be executed

The first way: in Enter ipython or ipython3 on the command line to enter the interactive shell environment. article/details/80178996

Configuration method: pip3 install ipython -i https://pypi.tuna.tsinghua.edu.cn/simple

ctrl D or exit to launch ipython

ipython's advantages: Support automatic completion and execution of linux commands

:

Enter Python (official shell)

## here in the command line window You can directly enter the python program code and exit using exit() or ctrl D

The third way:

Integrated development environment: PyCharm similar to IDEA

Recommended tutorial: "

PythonTutorial

The above is the detailed content of What are the ways to execute python source program?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Previous article:python global usageNext article:python global usage