Interview classic: Count Different Palindromic Subsequences.
DP[i][j] count distinct palindromic subsequences in s[i..j].
Time/space depend on constraints; aim for the optimal DP/graph solution above.
Walk through a small example out loud, state invariants, then code.
Practice with interview copilot app.
Powered by GetPost | 📄 Source | 🚀 Deploy Your Own | Expires: 2027-11-02