CS101 · Programming & Abstraction
Learning materials — teaching, weekly quizzes, weekly tests. Examination paper — 2 h 30 · 100 marks · grade descriptors · every question mapped to a chapter.
Credits 8 · Hours 80 · Prereqs none · Semester 1
Source course
Section titled “Source course”MIT 6.100L — Introduction to CS and Programming using Python (Fall 2022), the full-semester version of 6.100A. Lectures: https://ocw.mit.edu/courses/6-100l-introduction-to-cs-and-programming-using-python-fall-2022/pages/lecture-notes/ Syllabus: https://ocw.mit.edu/courses/6-100l-introduction-to-cs-and-programming-using-python-fall-2022/pages/syllabus/
Assigned text: John Guttag, Introduction to Computation and Programming Using Python, 3rd ed., MIT Press (2021), ISBN 9780262542364. The course states the book and lectures parallel each other.
Harvard CS50x is not used as the spine: its only Python week is Week 6, the rest is C/Python/SQL/JS survey. (https://cs50.harvard.edu/x/2024/weeks/6/)
Objectives
Section titled “Objectives”- Read any function in
backend/and state its contract, inputs, and mutations. - Write a function, class, and test from a written specification.
- Diagnose a failure from a traceback without guessing.
- See why a value-vs-reference mistake corrupts a Django queryset.
Weekly map
Section titled “Weekly map”| Wk | MIT 6.100L lectures | Topic |
|---|---|---|
| 0 | — | Bootcamp: shell, Git, pdb, nix develop .#backend, running backend/ |
| 1 | 1–2 | Strings, input/output, branching |
| 2 | 3–4 | Iteration, loops over strings, guess-and-check, binary search |
| 3 | 5–6 | Floats, approximation, bisection |
| 4 | 7–8 | Decomposition, abstraction, functions, functions as objects |
| 5 | 9–11 | Lambda, tuples, lists, mutability, aliasing |
| 6 | 12–13 | List comprehension, testing, debugging, exceptions, assertions |
| 7 | 14 | Dictionaries |
| 8 | 15–16 | Recursion, recursion on non-numerics |
| 9 | 17–19 | Classes, methods, inheritance |
| 10 | 20–21 | OOP worked example, timing programs |
| 11 | 22–24, 26 | Big-O and Theta, complexity classes, sorting, hashing |
| 12 | — | Reading week |
FTM labs
Section titled “FTM labs”- L1 run
backend/locally, hit one endpoint, read the traceback of a forced error. - L2 write the contract (args, returns, raises, mutates) for three functions in
backend/shared/; check each against the body. - L3 journal-export parser, with pytest tests.
- L4 four seeded defects on a scratch branch, each fixed test-first.
Project
Section titled “Project”CLI reporting worker/job failures from a journal export. Tested, reviewed, ~200 lines.
Reading list
Section titled “Reading list”| Book | Author, year | Use | Free |
|---|---|---|---|
| Introduction to Computation and Programming Using Python, 3rd ed. | John Guttag, 2021 | Assigned text; parallels the lectures | No |
| Think Python, 2nd ed. | Allen B. Downey, 2015 | Gentlest chapter-by-chapter spine if a lecture doesn’t land; greenteapress.com/wp/think-python-2e | Yes |
| Automate the Boring Stuff with Python, 2nd ed. | Al Sweigart, 2019 | Scripting for a working QA engineer: files, spreadsheets, browser; autbor.com | Yes |
| Python Crash Course, 3rd ed. | Eric Matthes, 2023 | Project-driven alternative if she wants to build sooner | No |
| Fluent Python, 2nd ed. | Luciano Ramalho, 2022 | Second pass: data model, iterators, idiomatic Python | No |
Assessment
Section titled “Assessment”Coursework 45% (L1–L4) · Project 35% · Check-off viva 10% · Exam 10%.
Theory deferred: complexity to CS202; induction to FTM302.