Omnissa·Software Engineer·Technical Phone Screen
- Given a string of lowercase letters, repeatedly remove pairs of adjacent identical characters until no such pairs remain. Return the final string.
“My first instinct was to just loop and scan repeatedly until nothing changed, which works but is obviously O(n^2) and they pushed back immediately when I mentioned the string could be up to 100k chars.”