Avatar ·

字典键可以是什么值?

📁 python, 错误

文档说只有不可变数据类型才能作为键。为什么在这种情况下没有报错?

class test: pass t = test() print ({t: 1})