What did you learn? Prefix sums generalize to higher dimensions. The pattern is the same: precompute cumulative values, answer queries by subtraction.
Inclusion-exclusion handles overlapping regions. When you add overlapping areas, subtract the intersection.
The offset pattern persists. It keeps edge cases clean in any dimension. Next, I'll show you the inverse operation. What if you need to update ranges instead of query them?