Day 4 Python Standard Library
Day 4 Python Standard Library
• Python 3
Standard Libraries in Pythons
• The core Python programming language comes with functions such as max()
and sum() and classes such as int, str, and list.
• In addition to the core functions and classes, Python has many, many more
functions and classes defined in the Python Standard Library.
• The Python Standard Library consists of thousands of functions and classes
organized into components called modules.
• Each module contains a set of functions and/or classes related to a particular
application domain.
• More than 200 built-in modules together form the Python Standard Library.
• Each module in the Standard Library contains functions and classes to support
application programming in a certain domain.
Standard Libraries in Pythons
• The fractions module makes available a new type of number: the Fraction
type.
• The Fraction type is used to represent fractions and do rational arithmetic,
such as:
• The Python interpreter treats the value entered as a string '5', not integer 5.
We check this:
Adding Two Numbers