Skip to content

Commit d581569

Browse files
refactor 1190
1 parent b76212e commit d581569

File tree

1 file changed

+0
-30
lines changed

1 file changed

+0
-30
lines changed

src/main/java/com/fishercoder/solutions/_1190.java

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -4,36 +4,6 @@
44
import java.util.Queue;
55
import java.util.Stack;
66

7-
/**
8-
* 1190. Reverse Substrings Between Each Pair of Parentheses
9-
*
10-
* You are given a string s that consists of lower case English letters and brackets.
11-
* Reverse the strings in each pair of matching parentheses, starting from the innermost one.
12-
* Your result should not contain any brackets.
13-
*
14-
* Example 1:
15-
* Input: s = "(abcd)"
16-
* Output: "dcba"
17-
*
18-
* Example 2:
19-
* Input: s = "(u(love)i)"
20-
* Output: "iloveu"
21-
* Explanation: The substring "love" is reversed first, then the whole string is reversed.
22-
*
23-
* Example 3:
24-
* Input: s = "(ed(et(oc))el)"
25-
* Output: "leetcode"
26-
* Explanation: First, we reverse the substring "oc", then "etco", and finally, the whole string.
27-
*
28-
* Example 4:
29-
* Input: s = "a(bcdefghijkl(mno)p)q"
30-
* Output: "apmnolkjihgfedcbq"
31-
*
32-
* Constraints:
33-
* 0 <= s.length <= 2000
34-
* s only contains lower case English characters and parentheses.
35-
* It's guaranteed that all parentheses are balanced.
36-
* */
377
public class _1190 {
388
public static class Solution1 {
399
public String reverseParentheses(String s) {

0 commit comments

Comments
 (0)