Access-review spreadsheets always want one row per membership, not a nested blob per user. Ten labs on Module 11 — now starting from an exported file, not the in-memory fixture.
Write USERS out to "p1_export.json", then read it back with json.load(). Print len() of the loaded data.
12Write flatten_memberships(users) — nested loops building one row per (user, group) membership, same fields as Module 11: email, lastName, department (guarded), group. Call it on the data you loaded in Lab 1. Print len().
15Write flatten_memberships_comp(users) — the same flattening as a single nested comprehension. Compare its result to Lab 2's with ==.
TrueFrom your flattened rows, find Layla's (guard her missing department). Print the matching row(s).
[{'email': 'lhaddad@example.com', 'lastName': 'Haddad', 'department': 'Unknown', 'group': 'Contractors'}]Confirm Dana has ZERO rows in the flattened output — she has no groups to flatten. Print the count.
0Sort your flattened rows by lastName. Print the first row's last name, then the last row's.
Chen then RiveraPrint the first 3 sorted rows as "LASTNAME -- GROUP (DEPARTMENT)".
Chen -- VPN-Users (Security)Chen -- SecOps (Security)Chen -- Admins (Security)
Write the sorted rows to "p8_report.txt", numbered with enumerate(..., start=1), same format as Lab 7 with a leading number.
Read "p8_report.txt" back. Print how many lines it has.
15Write USERS to "p10_export.json" → read it back → flatten → count distinct groups → sort → write a numbered report to "p10_report.txt" → print "N rows, M groups" → read the report back and print its line count.
15 rows, 6 groups then 15Open problems/tier09_membership_flattener.py and do all 10 problems locally. Uses fixture.py -- type it in first from DAY1_01_FIXTURE.md if it's not already in this folder. Run python check.py in problems/ to grade everything.