← ALL NOTES
Hash Table

1930. Unique Length-3 Palindromic Subsequences

Given s, count the distinct length-3 palindromic subsequences (form xyx). Distinctness is by content, not by position. For each outer letter x, the answer is the number of distinct middle letters…

Loading…