File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -285,16 +285,17 @@ Sequences
285285 single: integer
286286 single: Unicode
287287
288- A string is a sequence of values that represent Unicode codepoints.
289- All the codepoints in range ``U+0000 - U+10FFFF `` can be represented
290- in a string. Python doesn't have a :c:type: `chr ` type, and
291- every character in the string is represented as a string object
292- with length ``1 ``. The built-in function :func: `ord ` converts a
293- character to its codepoint (as an integer); :func: `chr ` converts
294- an integer in range ``0 - 10FFFF `` to the corresponding character.
288+ A string is a sequence of values that represent Unicode code points.
289+ All the code points in the range ``U+0000 - U+10FFFF `` can be
290+ represented in a string. Python doesn't have a :c:type: `char ` type;
291+ instead, every code point in the string is represented as a string
292+ object with length ``1 ``. The built-in function :func: `ord `
293+ converts a code point from its string form to an integer in the
294+ range ``0 - 10FFFF ``; :func: `chr ` converts an integer in the range
295+ ``0 - 10FFFF `` to the corresponding length ``1 `` string object.
295296 :meth: `str.encode ` can be used to convert a :class: `str ` to
296- :class: `bytes ` using the given encoding, and :meth: ` bytes.decode ` can
297- be used to achieve the opposite.
297+ :class: `bytes ` using the given text encoding, and
298+ :meth: ` bytes.decode ` can be used to achieve the opposite.
298299
299300 Tuples
300301 .. index ::
You can’t perform that action at this time.
0 commit comments