Assignments
|
PublishedNov 11, 2026
Updated—
DueNov 17, 2026
|
Counting loops, a loop inside a loop, and map, filter and fold written by hand; then Pascal’s triangle, and the picture hiding in it. |
|
PublishedNov 4, 2026
Updated—
DueNov 10, 2026
|
A taxi’s day again, walked with while loops: sums and counts with a name that changes, a loop that stops early, lists that come out backwards; then loops with no list behind them. |
|
PublishedOct 28, 2026
UpdatedOct 29, 2026
DueNov 3, 2026
|
A taxi’s day as a list of rides: filter and map for which rides and where to, fold for the takings and the route, each a line with an arrow in it; then seven by hand, with a switch on the list, four of them carrying a value down the calls. |
|
PublishedOct 21, 2026
Updated—
DueOct 27, 2026
|
A1’s flags with |
|
PublishedOct 14, 2026
Updated—
DueOct 20, 2026
|
The cinema’s rules: a chain of |
|
PublishedOct 7, 2026
UpdatedOct 9, 2026
DueOct 13, 2026
|
Six small functions that decide: |
|
PublishedSep 30, 2026
Updated—
DueOct 6, 2026
|
Builders that change in place, four predictions checked before they run, and a die you can test because its seed is fixed. |
|
PublishedSep 23, 2026
Updated—
DueSep 29, 2026
|
The stripe and the flag drawn in text, with |
|
PublishedSep 9, 2026
UpdatedSep 14, 2026
DueSep 15, 2026
|
One question, asked of a whole list. First with the built-in list functions, then by writing one yourself, then about people rather than stripes. |
|
PublishedSep 2, 2026
Updated—
DueSep 8, 2026
|
Programs that branch. Small, because Week 2 is a single class. |
|
PublishedAug 26, 2026
UpdatedSep 7, 2026
DueSep 1, 2026
|
Build a flag in Pyret, replace every repeated number with a name so the whole thing scales from one value, then turn it into a function you can call at three different sizes. |
Postmortems
Written after an assignment is marked and returned: the mistakes that showed up in enough files to be worth explaining once, and the places the assignment page itself was the problem. Nothing here is graded — but the errors in it are the ones that will cost points next time.
| Title | Description |
|---|---|
| A7 postmortem — what a reader needs | A file laid out to be read, a value named once, a switch Java can check, and why null has no place in this course’s programs. |
| A3 postmortem — where the answer came from | Both of this week’s findings are the same mistake wearing two hats: the answer was read off the code instead of worked out from the rule. |
| A2 postmortem — the order of the questions | Eight of fifteen files answer every case correctly. The other seven all have a green test suite, and that is the interesting part. |
| A1 postmortem — what the class got wrong | The mistakes that came up in enough files to be worth writing once rather than seventeen times, and the two the assignment page caused. |
Exams
TBD