Java | without using stack | simple one
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution {\n    public String removeOuterParentheses(String s) {\n       String res="";\n       int k=0;\n       int op=0;\n       for(int i=0;i<s.length();i++)\n       {\n           if(s.charAt(i)==\'(\')op++;\n           else op--;\n           if(op==0){\n               res+=help(s.substring(k,i+1));\n               k=i+1;\n           }\n       }\n       return res;\n    }\n\n    public static String help(String str)\n    {\n        return str.substring(1,str.length()-1);\n    }\n}\n\n/*\n s = "(  ()()   )    (  ()   )"\n int k=0;\n open=0;close=0;\n ( op=1  ( op=1\n (op=2   ( op=2\n )op=1   ) op=1\n (op=2   ) op=0\n )op=1\n)op=0\nwhen op becomes 0 (op=0) , we gonna found one decompose string and removing it\'s outer most parenthese\n*/\n\n```
['Java']