Remove Adjacent Almost-Equal Characters at Salesforce
Medium53.1% acceptance
This problem has 75.0% frequency at Salesforce.
Problem Description
You are given a **0-indexed** string `word`. In one operation, you can pick any index `i` of `word` and change `word[i]` to any lowercase English letter. Return _the**minimum** number of operations needed to remove all adjacent **almost-equal** characters from_ `word`. Two characters `a` and `b`...
Read full problem and hintsTopics
More Salesforce Questions
Minimum Operations to Reduce an Integer to 0MediumString CompressionMediumMaximum Number of Occurrences of a SubstringMediumSmallest Substring With Identical Characters IIHardTime Needed to Rearrange a Binary StringMedium
View all Salesforce questions