Problem 4062 · Medium

Transform Array Using Pair Operations

Each pair operation keeps the pair total, so the whole array total is invariant. Equal totals let every position be set in turn.

Open the interactive visualisation