Presentation is loading. Please wait.

Presentation is loading. Please wait.

Python’s STD Library Part II.

Similar presentations


Presentation on theme: "Python’s STD Library Part II."— Presentation transcript:

1 Python’s STD Library Part II

2 Output Formatting “repr” module
Abbreviated displays of large or deeply nested containers:

3 Output Formatting Cont.
“pprint” module Printing built-in and user defined objects Adds line breaks and indentation

4 Output Formatting Cont.
“textwrap” module Formats paragraphs of text to fit given screen width

5 Output Formatting Cont.
“locale” module Accesses database Culture specific data formats

6 Templating “string” module Includes versatile template class
$ signifies beginning of python identifier

7 Templating Cont. Template subclasses -> specify custom delimiter
(Other than $)

8 Binary Data Record Layouts
“struct” module pack() and unpack() functions

9 Multi-Threading Threading allows multiple tasks to be running simultaneously

10 Logging Controls: Where debugging messages occur
How they are processed

11 Weak References “weakref” module
Tracking objects without creating reference

12 Tools for Lists “array” module Homogeneous data stored compactly

13 Tools for Lists Cont. “collections” module
Faster appends and pops from left Slower lookups in middle

14 Tools for Lists Cont. “bisect” module Manipulating sorted lists

15 Tools for Lists Cont. “heapq” module Heaps based on regular lists

16 Decimal Floating Point Arithmetic
“decimal” module Calculations requiring more precision


Download ppt "Python’s STD Library Part II."

Similar presentations


Ads by Google