As Python’s popularity soars, more and more people are starting to learn Python. In the process of learning, more and more problems arise. Next, I will take you through how to save Python code. You have to pay attention to the programming environment you use.
1. Under Windows system, if you write code directly using the command line, it cannot be saved.
2. Under Linux system, use vi to type esc, then: wq to save.
3. If you are using an IDE, under normal circumstances, just save it directly or ctrl S, the suffix is .py
Related learning recommendations: python tutorial
The above is the detailed content of How to save python code?. For more information, please follow other related articles on the PHP Chinese website!