Learning preparation for the Python standard library

Source: Internet
Author: User

Vamei Source: Http://www.cnblogs.com/vamei Welcome reprint, Please also keep this statement. Thank you!

Python's standard library is a powerful force for Python, as we've already described in the previous article. Because the standard library involves a wide range of applications, it is necessary to learn some background knowledge.

Hardware Principles

This part needs to understand the functions and performance of memory, CPU, disk storage and Io, understand the process of computer work and understand the concept of instruction. These elements are fundamental and important.

Part of the Python standard library is to improve the performance of the system (such as mmap), so it is necessary to understand the performance of the various components of the basic computer.

Operating System

When you understand the operating system, the following are the highlights:

1) process management of the operating system, such as what is UID, PID, daemon

2) signal communication between processes, such as how to transmit signals using kill

Learning Process-related content is designed to facilitate learning OS packages, thread packs, multiprocessing packages, signal packages

3) file management, several types of files.

4) file read/write (IO) interface

5) file permissions and other file information (meta data)

6) common system commands and applications such as LS, MV, RM, mkdir, chmod, zip, tar ...,

Learn about file-related content, which is to learn about the OS package, shutil the file management related parts of the package. Learning the file interface is important for understanding the text input and output, and it also affects the understanding of the socket package and the concept of the Select package. In addition, the Archive (archive) and compression (compress) features in Python are similar to those in the operating system.

7) The Linux shell, such as file name matching, is useful for understanding glob packages. If you have a good understanding of the regular expressions of Linux (regular expression), the learning of the regular expression of Python becomes easier. Learning parameter passing in the Linux command line is also useful for understanding the packages in the Python standard library that parse the command line.

Network

One of the big applications of Python is in the web. But Python and the standard library simply provide interfaces and do not involve the underlying. Network knowledge can greatly reduce the steepness of learning curve.

1) A layered architecture based on TCP/IP. This content is too broad, so you can have a selective understanding of the backbone of knowledge.

2) commonly used application layer protocols, such as http, and mail-related protocols, especially their working processes.

3) According to the needs, understand html/css/javascript/jquery/frame, etc.

This knowledge is needed if you want to build a server using Python, such as on Google App engine.

algorithms and data Structures

The standard library defines the encapsulation of some data objects. Therefore, you do not need to write them all over again. The application of related data structures requires knowledge of some data structures, such as queues, trees, etc.

Many algorithms have been implemented in the standard library, such as sorting, which can be conveniently called. The basics of algorithms can help you make decisions.

Database

The sqlite3 is built into Python. If you only need a simple database, you can call sqlite3 directly from the standard library.

When using database-related packages in Python, such as sqlite3, you need to have a basic understanding of the database, especially the relational database.

encryption and text encoding

Python's cryptographic algorithms are also based on some classic cryptographic algorithms, such as the MD5,RSA algorithm. The basics of cryptography will be helpful.

The knowledge of text encoding is important when using non-ASCII encodings, such as Chinese.

Summary

Python's basic object concepts and dynamic type concepts. You can refer to the quick tutorials and try to read more information and source code to deepen your understanding of the concept. The difficulty with Python's standard library learning is background knowledge. A programmer who knows the relevant background (or a library of other languages) can master the Python base library in a very short period of time.

Learning preparation for the Python standard library

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.