Built-in Data Structures: Lists
摘要
A data structure is a collection of organized data stored in computer memory and the operations permitted on the data. These operations help in writing efficient programs by providing fast access to the data. Python provides built-in data structures as well as constructs to create user-defined data structures. Python provides class construct to define user-defined data structures. Python built-in data structures include lists, tuples, dictionaries, sets, and strings. These basic data structures cover most of the real-world data structures for data manipulations. The basic built-in data structures differ in the following ways: (i) whether the object can be changed after creating it, called mutability. (ii) whether the elements of the object can be accessed based on their position in the object, called sequence object.