Article directory
write python code
According to the knowledge we introduced before, we know that the so-called code is actually a piece of ordinary text written according to certain specifications, and then handed over to the computer for analysis and execution. Since it is a piece of text, can we directly use a text editor to encode it? The answer is yes, but when developed in this way, the efficiency will be very low.
1. Common code editing tools
In fact, in our actual work, if we only want to view a certain (several) files, we really use a simple code editing tool to do it.
Common code editing tools:
-
vim (commonly used code editing tool under Linux system)
-
sublime (a cross-platform, easy-to-use code editing tool)
-
notepad++ (a code editing tool running on Windows platform)
The several software development tools introduced above may be used in our work. They all have the function of code highlighting. Some tools can also realize more powerful functions such as automatic code prompting through plug-ins.
2. Run the Python program
Python is an interpreted language that can be executed directly using an interpreter without a compiler. Open a terminal and enter the following command:
python hello.py
Running the hello.py file will output hello world on the console
3. Download and install Pycharm
Although the software described above has been able to improve our coding speed, it still cannot cope with the more complex requirements in our development. In general, we all need tools to help us quickly build the environment, write code, and run programs.
The concept of IDE IDE (Integrated Development Environment) is also known as an integrated development environment. To put it bluntly, there is a software with a graphical interface, which integrates functions such as editing code, compiling code, analyzing code, executing code and debugging code. In our Python development, the most commonly used IDE is Pycharm.
PyCharm is an IDE developed by Czech company JetBrains, which provides code analysis, graphical debugger, integrated tester, integrated version control system, etc., and is mainly used to write Python code.
Download address: http://www.jetbrains.com/pycharm/download
The main functional areas of PyCharm
- File navigation area: ability to browse/locate/open project files
- File editing area: able to edit the currently opened file
- Console area: able to output program execution content and track the execution of debugging code
Advanced case
[Python] Python realizes the word guessing game-challenge your intelligence and luck!
[python] Python tkinter library implements GUI program for weight unit converter
[python] Use Selenium to get (2023 Blog Star) entries
Use Tencent Cloud Cloud studio to realize scheduling Baidu AI to realize text recognition
[Xiaobai must see] Python word cloud generator detailed analysis and code implementation
[Xiaobai must see] Python crawls an example of NBA player data
[Must-see for Xiaobai] Sample code for crawling and saving Himalayan audio using Python
[Xiaobai must see] Python crawler data processing and visualization
[Must-see for Xiaobai] Python crawler program to easily obtain hero skin pictures of King of Glory
[Must-see for Xiaobai] Use Python to generate a personalized list Word document
Geospatial data processing and visualization using geopandas and shapely (.shp)
Use selenium to crawl Maoyan movie list data
Detailed explanation of the principle and implementation of image enhancement algorithm Retinex
Getting Started Guide to Crawlers (8): Write weather data crawler programs for visual analysis
Getting started with crawlers (4): The best way to crawl dynamic web pages using Selenium and API
Getting Started Guide to Crawlers (3): Python network requests and common anti-crawler strategies
Getting started with crawlers (2): How to use regular expressions for data extraction and processing
Getting started with reptiles (1): Learn the basics and skills of reptiles
Python object-oriented programming basics and sample code
MySQL database operation guide: learn how to use Python to add, delete, modify and query operations
Python file operation guide: encoding, reading, writing and exception handling
Selenium Automation Toolset - Complete Guide and Tutorials
Python web crawler basics advanced to actual combat tutorial
Pandas data processing and analysis tutorial: from basics to actual combat
Detailed explanation of commonly used data types and related operations in Python
[Latest in 2023] Detailed Explanation of Six Major Schemes to Improve Index of Classification Model