day5 class notes to remember

Data Type
Integer
String
list, a tuple
search
index (subscript) are from 0
slice
.count check the number of occurrences of an element
.index the contents of the location to find the corresponding
"haidilao ge" in a
increase
a.append () additional
a.insert (index, "content")
a.extend extension

Modifying
a [index] = "new value"
A [Start: End] = [A, B, C]

Delete
remove ( "Content")
POP (index)
del A, del A [index]
a.clear () Clear

Sort
the Sort ()
Reverse ()

Identity judgment
>>> of the type (A) IS List
True
>>>

Guess you like

Origin www.cnblogs.com/bdua/p/12147971.html