Home >Common Problem >How to save .py in python

How to save .py in python

silencement
silencementOriginal
2019-05-17 16:17:2541089browse

How to save and run the written Python code? In what format do you want to save it? Let's take the IDE that comes with Python as an example to talk about this problem.

How to save .py in python

Double-click the desktop ide icon to open, shortcut key ctrl n Create a new folder, write our Python code in the newly created question markup, and write it After running F5, there will be the following prompt

How to save .py in python

Click OK, as follows,

How to save .py in python

Note : The file name of Python must end with .py, and the file type is Python files

Running result

How to save .py in python

When naming the file, The name should avoid conflict with Python keywords.

The above is the detailed content of How to save .py in python. 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