不浅专题

Python3 正常显示出十六进制(坑人不浅)

Python3 自动转Unicode有时候真的是很烦人啊!! 直接上方法 input_data = b'WAV\x04\xbc\x04\x00RR'def print_hex(bytes):'''在Python3下打印出十六进制字节串'''l = [hex(int(i)) for i in bytes]return l print_hex(input_data) ['0x57', '0x