Created
November 24, 2020 14:40
-
-
Save ahmet-cetinkaya/de9f196deeb6ed23847f6cf4567b09bc to your computer and use it in GitHub Desktop.
LeetCode Solution 1047. Remove All Adjacent Duplicates In String
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const removeDuplicates = (S) => S.match(/(.)\1/g) ? removeDuplicates(S.replace(/(.)\1/g, '')) : S; |
Author
ahmet-cetinkaya
commented
Nov 24, 2020
•
- Leetcode Discuss
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment