Problem 1788 · Medium

Maximize the Beauty of the Garden

Pick two flowers with equal beauty as the ends of a garden, then add every positive flower between them to maximise the total.

Open the interactive visualisation