7. String ServicesΒΆ
The modules described in this chapter provide a wide range of string manipulation operations.
In addition, Pythonβs built-in string classes support the sequence type
methods described in the Sequence Types β str, unicode, list, tuple, bytearray, buffer, xrange section, and also the
string-specific methods described in the String Methods section.
To output formatted strings use template strings or the % operator
described in the String Formatting Operations section. Also, see the
re module for string functions based on regular expressions.
- 7.1.
stringβ Common string operations - 7.2.
reβ Regular expression operations - 7.3.
structβ Interpret strings as packed binary data - 7.4.
difflibβ Helpers for computing deltas - 7.5.
StringIOβ Read and write strings as files - 7.6.
cStringIOβ Faster version ofStringIO - 7.7.
textwrapβ Text wrapping and filling - 7.8.
codecsβ Codec registry and base classes - 7.9.
unicodedataβ Unicode Database - 7.10.
stringprepβ Internet String Preparation - 7.11.
fpformatβ Floating point conversions
