create a regex that knows balanced parenthesis with maximum depth of 5
create a regex that knows balanced parenthesis with maximum depth of 5 Question: I have a problem with a regex, it is supposed to match if the depth is between 1 or 5, for example it should match with “()()()”, “((((()))))”, “(()((()))())” and not match with “())()”, “(((((())))))” och “(x)”. I have this pattern = …