Problem 3406 · Medium

Find the Lexicographically Largest String From the Box II

Every part from every split is a candidate; the answer is a trimmed largest suffix, so two moving starts find it without listing the parts.

Open the interactive visualisation