In python, I'm trying to convert a string literal to it's hexadecimal 4 byte equivalent. Here's an example of what I'm doing:
import struct
struct.pack("<i", int("08050030", 16))
>>'0\x00\x05\x08'
Why is the output rendering like this? I would expect \x30\x00\x05\x08?
'0' == '\x30'. If the character can be represented as a ascii character, it is displayed as the chracter instead of\xOOform.