基本上我想这样做:
obj = 'str' type ( obj ) == string
我试过了:
type ( obj ) == type ( string )
它不起作用.
另外,其他类型呢?例如,我无法复制NoneType.
NoneType
python types compare
compare ×1
python ×1
types ×1