mytupleone = ("Hello", 250, (3, "byebye"))
mytupletwo = ("Hello", 250, (3, "byebye"))
print(mytupleone is mytupletwo)
mytuplethree = ("Hello", 250, (3, [1, 2, 3]))
mytuplefour = ("Hello", 250, (3, [1, 2, 3]))
print(mytuplethree is mytuplefour)
运行结果:
True
False
mytupleone = ("Hello", 250, (3, "byebye"))
mytupletwo = ("Hello", 250, (3, "byebye"))
print(mytupleone is mytupletwo)
mytuplethree = ("Hello", 250, (3, [1, 2, 3]))
mytuplefour = ("Hello", 250, (3, [1, 2, 3]))
print(mytuplethree is mytuplefour)
运行结果:
True
False