Problem 3888 · Medium

Minimum Operations to Make All Grid Elements Equal

Raise every cell to a common target by stacking k by k square increments, placing each forced square at the first cell that still needs it.

Open the interactive visualisation