Integer to Hexadecimal Conversion in Python

后端 未结 6 1732
执念已碎
执念已碎 2021-01-13 11:37
a = 1
print hex(a)

The above gives me the output: 0x1

How do I get the output as 0x01 instead?

6条回答
提交回复
热议问题