πŸ“ 2D Difference Array β€” Update & Rebuild Demo
2D Diff Array O(1) update / O(RC) rebuild Step 0/20
πŸ“Š Visualization
πŸ—‚ Data Structures
Current Operation
diff[][] Grid
Update: O(1) per rectangle
Rebuild: O(RΓ—C)
πŸ’» Code
HintClick Next Step β–Ά to see how 2D difference arrays handle rectangle updates with 4 corner marks, then rebuild via 2D prefix sum.
0/20

Keyboard: β†’ Next   ← Prev   R Reset