Problem 135 · Hard
Two passes left-to-right and right-to-left to enforce neighbor rating constraints.
Open the interactive visualisation