We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Algorithms
- Strings
- Super Reduced String
- Discussions
Super Reduced String
Super Reduced String
Sort by
recency
|
1722 Discussions
|
Please Login in order to post a comment
RUST:
Best Approche Cpp
string superReducedString(string s) { stackstack;
}
Here is my c++ solution, you can watch the explanation here : https://youtu.be/XgJKCkb1EjQ
Here is my Python solution!
solution in python
def superReducedString(s): # Write your code here pat=r'(.)\1' while True: rs=re.sub(pat,'',s) if s==rs: break s=rs return 'Empty String' if len(s)==0 else s