Python Program to Convert Bytes to a String
decode() method:-
Python provides the built-in decode() method, which is used to convert bytes to a string. Let's understand the following example.
code:-
print(b'Easy \xE2\x9C\x85'.decode("utf-8"))
output:-
Easy ✅
>>>
Post a Comment
If you have any doubts, Please let me know
Thanks!