Summary
I walk students through a fresh Google Colab notebook, showing them how to save the file to their Drive and emphasizing that every cell must be run from top to bottom; skipping a cell will leave variables undefined. I then review the core data types—integers, floats, and strings—and demonstrate variable assignment, highlighting that assigning copies the current value and later changes to the original do not affect earlier copies. I cover naming conventions (letters or underscores first, case‑sensitive, no keywords) and the distinction between mutable reassignment and immutable values. Basic arithmetic operators (+, -, *, /, ** for exponentiation, // for floor division) are illustrated, with floor division linked to later spreadsheet calculations.
Next, I introduce the modulo operator using a 12‑hour clock to explain remainders and note its usefulness for circular calculations. I briefly discuss how computers represent numbers in binary and other bases (hexadecimal, base‑32/64) for compact data storage. I then shift to string handling: concatenation with +, f‑strings for interpolation, and repetition with *. With these tools, I guide students to code a BMI calculator (BMI = weight kg ÷ height m²), stressing the use of variables, parentheses for clarity, and the need for the result to be a float. I run the automatic grader, point out that it expects a float and will fail if cells are out of order, and troubleshoot a common grader error. Finally, I invite questions and remind learners to keep the notebook saved and executed sequentially so that their code and the grader align.
Action items: save the notebook to Drive, execute cells in order, follow naming rules, use appropriate arithmetic operators, apply modulo when needed, format strings with f‑strings, and ensure the BMI output is a float for the grader. These steps prepare students to build reliable Python scripts in Colab and lay the groundwork for later spreadsheet integration.