Python Modules, Dates & Math
Lesson Overview: Organize multi-file apps with import and leverage datetime, math, and random.
Batteries Included
Python ships hundreds of built-in modules ready to import without installing external packages.
- import math, datetime, random
- from pathlib import Path for cross-platform paths
Test Yourself With Exercises
Import only the sqrt function from the math module:
math import sqrt