How to get the unique id of a tuple in Python

1 Answer

0 votes
tpl = ('python', 'c++', 'java', 'php')

tid = id(tpl)

print(tid)


'''
run:

5779696

'''

 



answered Dec 12, 2018 by avibootz
...