lists can be modified without replacing the original object : id « Buildin Function « Python Tutorial






aList = ['A', 83, 85, 'B']
print aList
print aList[2]
print id(aList)
aList[2] = aList[2] + 1
aList[3] = 'C'
print aList
print id(aList)
print aList.append('D')
print aList.append(aList[2] + 1)
print aList
print id(aList)








13.24.id
13.24.1.access the identity
13.24.2.whether objects are being changed
13.24.3.lists can be modified without replacing the original object
13.24.4.Displaying an object's location, type and value.