Decoding

The transformation from a byte string to a Unicode code point is known as decoding. So, let's see an example of how to decode a byte string to get a Unicode code point as shown in following code:

>>> str = bytes('Office', encoding='utf-8')
>>> dec_str = str.decode('utf-8')
>>> dec_str
'Office'
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset