Python for Beginners
Grade Levels: Grade 12
Educational System: American
Learn Python programming from scratch.
#Python
1. Configure and operate a Python 3 development environment using CPython, venv, pip, and an IDE or REPL.
Learning Targets:
1. Install CPython 3.x and verify the interpreter from the command line (e.g., python --version).
2. Create and activate an isolated virtual environment with python -m venv and confirm site-packages are sandboxed.
3. Manage packages with pip (install, upgrade, uninstall) and export dependencies with pip freeze > requirements.txt.
4. Configure VS Code (or comparable IDE) to run Python scripts, open an integrated terminal, and launch the REPL.
5. Run Python code from the terminal, in the REPL, and in a Jupyter Notebook to validate the toolchain.
Modules
1. Python 3 Toolchain Foundations
1. 1. Install CPython 3.x and Verify the Interpreter
Learning Outcomes:
1. Download the official CPython 3.x installer or package via platform-appropriate channels and select options for PATH integration.
2. Execute the installation and verify python --version and pip --version return expected versions on the command line.
3. Configure multiple Python versions and print sys.version to confirm the active interpreter.
4. Upgrade pip safely using python -m pip install --upgrade pip and confirm the updated version.
5. Diagnose and resolve PATH conflicts by inspecting where python/where pip (Windows) or which python/which pip (Unix) outputs.
6. Document installation steps and capture a verification transcript with commands and outputs for reproducibility.
1. 2. Command-Line Proficiency for Python
Learning Outcomes:
1. Execute python -c and python -m commands to run inline code and standard modules from the CLI.
2. Launch the interactive REPL, evaluate expressions, import modules, and exit cleanly using exit() or Ctrl-D/Z.
3. Navigate the filesystem with cd and list files with ls/dir and run scripts using python path/to/script.py via relative and absolute paths.
4. Configure shell profiles to define Python aliases or leverage the py launcher on Windows for version selection.
