How to decode a UTF-8-encoded byte string in Python

1 Answer

0 votes
byte_string = b"\x61\x62\x63\x64"

decode = byte_string.decode("utf8")

print(decode)



'''
run:

abcd

'''

 



answered Aug 8, 2020 by avibootz

Related questions

1 answer 163 views
1 answer 119 views
1 answer 185 views
1 answer 253 views
1 answer 189 views
189 views asked Jul 16, 2016 by avibootz
...