What is Python? Python introduction

Python (KK English pronunciation: /’pa) n/, DJ English pronunciation: Pai theta n/) is an object-oriented, literal computer programming language, which was invented at the end of 1989 by Guido van Rossum. The first public release was issued in 1991. Python syntax is simple and clear, with rich and powerful class libraries.

Python Code picture

It is often nicknamed Glue Language, and it is easy to connect modules made in other languages (especially C/C++). One common application is to use Python to quickly generate the prototypes of the program (sometimes even the final interface of the program), and then rewrite in a more suitable language for some of the parts of the program that have special requirements. For example, the 3D game graphics rendering module, speed requirements are very high, you can use C++ rewrite.

The main features of Python
1, Python is simple
Python is a language that represents simplistic ideas. Reading a good Python program feels like reading English. It allows you to focus on solving problems rather than understanding the language itself.
2, Python easy to learn
Python is extremely easy to use, because Python has an extremely simple syntax.
3, Python free, open source
Python is one of FLOSS (Free / Open Source Software). Users are free to publish copies of the software, read its source code, make changes to it, and use part of it in new free software. FLOSS is based on the concept of a group sharing knowledge.
4, Python high level language
Writing a program in Python does not require consideration of underlying details such as how to manage the memory your program uses.
5, Python transplantable
Because of its open source nature, Python has been ported to many platforms (modified to work on different platforms). These platforms include Linux, Windows, FreeBSD, Macintosh, Solaris, OS/2, Amiga, AROS, AS/400, BeOS, OS/390, z/OS, etc.
6, Python interpretative
A program written in compiled languages such as C or C++ can be converted from the source file (C or C++ language) to a language used by your computer (binary code, 0 and 1). This process is accomplished by a compiler and different tags and options.
When running a program, the Connector/Reproducer software copies your program from the hard disk into memory and runs it. Programs written in Python do not need to be compiled into binary code. You can run the program directly from the source code.
Within the computer, the Python interpreter converts the source code into an intermediate form called a bytecode, and then translates it into a machine language used by the computer and runs. This makes it easier to use Python. It also makes the Python program easier to transplant.
7, Python object oriented
Python supports both process-oriented and object-oriented programming. In a “process-oriented” language, a program is built from a process or just a function of reusable code. In object-oriented languages, programs are constructed from objects that combine data and functionality.
8, Python extensibility
If a critical section of the code is needed to run faster or if some algorithms are not open, some programs can be written in C or C++, and then used in the Python program.
9, Python Embeddedness
Python can be embedded into C/C++ programs to provide scripting capabilities to program users.
10, Python rich library
The Python standard library is really huge. It can help handle a variety of tasks, including regular expressions, document generation, unit testing, threads, databases, web browsers, CGI, FTP, e-mail, XML, XML-RPC, HTML, WAV files, password systems, GUI (graphical user interface), Tk, and other related operations. This is called the “fully functional” concept of Python. In addition to the standard library, there are many other high-quality libraries, such as wxPython, Twisted and Python image libraries and so on.
11, Python specification code
Python uses forced indentation to make the code more readable. Programs written in Python do not need to be compiled into binary code.

The advantages of Python
Python is an open source programming language without limitation and cross platform. It is powerful and easy to learn. Therefore, it has been widely used and supported.
Python is introduced into the ArcGIS9.0 community. Since then, Python has been regarded as a scripting language that can be geographically processed by users and has been continuously developed. Each version has further enhanced the Python experience, providing you with more functions and richer, more friendly Python experience.
ESRI has fully incorporated Python into ArcGIS and regarded it as a language that meets the needs of our users’ communities. The following are some of the advantages of Pytho:
Easy to learn, very suitable for beginners, and especially suitable for experts.
Highly scalable, suitable for large projects or small one-time programs (called scripts).
Transplantable, cross platform
Embeddable (making ArcGIS scripts)
Stable and mature
The large scale of the user community
Python has been extended to ArcGIS as a language for data analysis, data conversion, data management, and map automation, and thus helps to improve work efficiency.

Python problem
1, the speed of operation is slow.
2, the domestic market is small.
3. There is a shortage of Chinese materials (few good Chinese Python materials are available). With the blessing of the community, several excellent textbooks have been translated, but there are many entry-level textbooks, and advanced content can only be seen in English.
4. There are too many choices of architecture, but it also shows that Python is better, attracts more talents and projects.

评论

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

微信扫一扫打赏