from enum import Enum class Type(Enum): a = 1 b = 2 print Type.a.value, Type.a._value_
这打印
1 1
_ value_和value有什么区别?
python enums
enums ×1
python ×1