在python中表示十六进制到64字节(64个字符)



;十六进制";需要用零来完成。

示例h=ed23被这样表示000000000000000000000000000000000000000000000000000000000000ed23

使用zfill((解决

hex = ed23
hex64character = hex.zfill(64)
print(hex64character)
>>>000000000000000000000000000000000000000000000000000000000000ed23

最新更新