- Binary, 01
- Octal, 01234567
- Decimal, 0123456789
- Hex, 0123456789ABCDEF
http://www.cnblogs.com/txw1958/archive/2012/07/19/2598885.htmlThe most important new feature of Python 3 is probably a clearer distinction between text and binary data. Text is always Unicode, represented by the STR type, and binary data is represented by the bytes type. Python 3 does not mix str and bytes in any implicit way, which makes the distinction between them particularly clear. You cannot stitch strings and byte packets, search for strings in a byte packet (or vice versa), or pass a string into a function with a byte packet (or vice versa). It's a good thing. A string can be encoded into a byte packet, and a byte packet can be decoded into a string.
<wiz_tmp_tag id= "Wiz-table-range-border" contenteditable= "false" style= "Display:none;" >
Python Basics-Ternary operations and bytes data