Madhusudan Singh wrote: > I am using binascii.b2a_hex to convert some binary data to hex. The > result is a two bit hex representation (i. e., without the leading > 0x). Surely you mean two-byte? > How do I convert the resulting two bit representation into an integer > ? int(foo, 16)