Disjoint subsequences in an array with maximum difference

mediumLast edited: September 19, 2025