Python does not need to declare type information because the Python variable identifier does not have a type.
When a list is created in Python, the interpreter creates an array-like data structure class in memory to store the information, and the data items are stacked up from bottom up (forming a stack). The index starts at 0.
Use the bracket notation to access the list data, such as movies[1].
List using:
cast=["Cleese", "Palin", "Jones", "", "Idle"]
Print (CAST) # #打印整个列表
Print (len (cast))
Print (Cast[0])
Add a data item at the end of the list, using the Append () method, such as Cast.append ("Gilliam")
Delete data from the end of the list, using the Pop () method, such as Cast.pop ()
Add a collection of data items at the end of the list, using the Extend () method, such as Cast.extend (["AA", "BB"])
Locate and delete a specific data item in the list, using the Remove () method, such as Cast.remove ("BB")
Add a data item in front of a specific location, using the Insert () method, such as Cast.insert (0, "CC")
Python Learning Note Two _ list