Python: different objects get the same id

前端 未结 2 658
暗喜
暗喜 2021-01-20 16:41

Looking at the following IPython (Python 3.7) session:

In [1]: id(\'hello\')                                                     
Out[1]: 140300950123104

In         


        
2条回答
  •  栀梦
    栀梦 (楼主)
    2021-01-20 17:19

    Two objects with non-overlapping lifetimes may have the same id() value.

提交回复
热议问题