int('0x01') 报错~~~ 咋办
1
fy 2017-04-21 14:41:32 +08:00 3
int('0xaa01', 16)
|
2
TerrenceSun 2017-04-21 14:56:53 +08:00
int('0x01',0)
|
3
nyanyh 2017-04-21 15:42:22 +08:00
struct.pack('i', '0x01')
|
4
Yingruoyuan 2017-04-21 17:53:04 +08:00 1
int(eval('0x01'))
|
5
aristotll 2017-04-21 18:41:15 +08:00
@Yingruoyuan eval 性能不好吧
|
7
Yingruoyuan 2017-04-22 10:39:43 +08:00
|