Session 4 Exercise — Pandas Basics

Optional enrichment — complete during the session if time allows, or finish independently on your fork.

Your Task

  1. Load exercises/data/outreach_contacts.csv
  2. Print the first 5 rows and a column summary
  3. Select only these columns: student_id, first_name, last_name, phone, zip_code
  4. Drop rows where phone is missing
  5. Print how many rows remain
  6. Save the result to exercises/data/outreach_contacts_cleaned.csv

Starter Script

Open session_04_exercise.py and fill in the blanks marked with # TODO:. Every blank is either a string value ("___") or a variable name (___). If you get stuck, the completed version is at session_04_answer.py.

Run from the repo root:

python exercises/session_04_exercise.py