Anonymous · shared experience1 Oct 2025 · 5 views
Coupang: Count subsequence matches with no two adjacent picks
Problem. Given a source pattern and a target string, count the ways to pick characters of the target, in order, that spell the source, with the rule that two neighbouring characters of the target can never both be picked.
Example. Source "abc" and target "abbccc" give 2.
What mattered. The candidate said the interviewer expected DFS with memoization over (position in source, position in target), with the skip rule built into the transition.
Comments 0
No comments yet. Ask the author something, or add what happened in your own round.