dataone = 8 print(id(dataone)) datatwo = 5 print(id(datatwo)) dataone = datatwo print(dataone) print(id(dataone)) print(datatwo) print(id(datatwo)) print(dataone is datatwo)
结果:
92496144
92496216
5
True
结果:
92496144
92496216
5
92496216
5
92496216
True