Given a string s, find the longest palindromic subsequence's length in s. You may assume that the maximum length of s is 1000.
Given a string s, we make queries on substrings of s. For each query queries[i] = [left, right, k], we may rearrange the substring s[left], ..., s[right], and then choose up to k of them to replace ...