Reviewing Python Programming

Understand Python Programming Basics
Published

January 20, 2025

Exploration

Activities

  • Tuesday and Thursday: Course introduction
    • Review the basic building blocks of a Python program:
      • Sequence
      • Selection
      • Iteration
    • Consider different ways to create collections in Python
    • Measure the performance trade-offs of Python’s collections
  • Friday: Submit algorithm engineering project one, start algorithm engineering project two (note that the first project requires only one week of work), and take the first algorithm engineering skill-check in the second half of the laboratory session

Project

Goal

To build and use a Python program, called containmentchecking, that runs benchmarks to measure the performance of in for list, tuple, and set, thereby enabling software engineers to pick the fastest collection for their program.

Steps

  • Click the link provided in Discord to get started on this project
  • Leverage Containment Checking as your template repository
  • Install the project’s dependencies using devenv and/or poetry
  • Follow the instructions to complete the project:
    • Week 1: Implement all of the modules in containmentchecking
    • Week 2: Design and conduct experiments and document experimental results
  • Schedule office hours if you have questions
Student Insights

Students who completed this project shared these insights:

  • “My biggest takeaway from this entire experience is that it’s important to know what kinds of inputs would be considered ‘large’, ‘small’, or ‘standard’ for whatever task you’re performing. Having that kind of information is crucial in being able to come up with good values to test to make sure the experiment is being performed correctly.” Jacob Allebach

  • “Throughout conducting my experiments, I learned that the tuple is the overall quickest container to use for containment checking. Especially when searching through super large values, I would definitely use a tuple. Lists were a close second to tuples, and Sets were extremely slow.” Aidan Dyga

Slides

Full Screen: Week Two: Exploring the Python Programming Language

Back to top