Problem 2357 · Easy

Make Array Zero by Subtracting Equal Amounts

Each operation removes the smallest positive value from every positive entry, so the answer is the number of distinct positive values.

Open the interactive visualisation