Skip to main content

Practice · 5 of 5

Q4: rim aggregation

CHALLENGE
Difficulty: intermediate+25 XP

Implement rimSum: the sum of border cells. Handle the degenerate shapes (1xN, Nx1 — every cell is border; 1x1 — the single cell) explicitly. This is a fencepost-style boundary test in grid form.

Back to lesson: Practice: FRQ 2D array lab