Reputation: 414
Why this there is so difference in output with printing bytearray?
While example 1 seems fine to me. I don't understand why output of example 2 isn't bytearray(b'\x2f')
?
# example 1
print(bytearray.fromhex('1f'))
# output bytearray(b'\x1f')
# example 2
print(bytearray.fromhex('2f'))
# output: bytearray(b'/')
Upvotes: 0
Views: 100