Problem 2002 · Medium

Maximum Product of the Length of Two Palindromic Subsequences

Pick two disjoint palindromic subsequences to maximize the product of their lengths. The visual shows how each character is assigned to one of the two subsequences.

Open the interactive visualisation