Problem 665 · Medium

Non-decreasing Array

Check whether a single adjustment to one value can make the sequence never decrease. The visual marks each descent and tests whether lowering or raising one side repairs it.

Open the interactive visualisation