I have an integer list in Python that should correspond to the following int values (which can be changed to hex byte values):
[10, 145, 140, 188, 212, 198, 210, 25, 152, 20, 120, 15, 49, 113, 33, 220, 124, 67, 174, 224, 220, 241, 241]
However, when I convert that list to a bytearray (using bytearray(nameOfList)), I get the following printout.
bytearray(b'\n\x91\x8c\xbc\xd4\xc6\xd2\x19\x98\x14x\x0f1q!\xdc|C\xae\xe0\xdc\xf1\xf1')
I can pull the correct values from this byte array, regardless of how it prints, but shouldn't the bytearray printout correspond to the hex values of the byte array? (I mean, it seems to mostly follow the hex values up until after \x0f, where it starts putting out gibberish...)
\x0f
you have 49='1' and 113='q', etc. asciitable.com – axblount\x..
– mgilsonlist(your_bytearray) == your_list
– jfs