Match Dictionary Words After Collapsing Consecutive Duplicates
Given a lowercase string s. It is a run-expanded version of a word: a character may have been repeated one or more times consecutively.
For example, collapsing consecutive duplicates in `"heell...
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Standard Input
Execution Result:
