simple cpp solution using stack
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 {\npublic:\n    string removeOuterParentheses(string s) \n    {\n        string ans="";\n        stack<char>st;\n        for(int i=0;i<s.length();i++)\n        {\n            if(st.empty()&&s[i]==\'(\')\n            {\n                st.push(\'(\');\n            }\n            else\n            {\n                if(st.size()>0 &&s[i]==\'(\')\n                {\n                    st.push(\'(\');\n                    ans+=\'(\';\n                }\n                else if(st.size()>1 && s[i]==\')\')\n                {\n                    st.pop();\n                    ans+=\')\';\n                }\n                else\n                {\n                    st.pop();\n                }\n            }\n        }\n        return ans;\n        \n    }\n};\n```
['String', 'Stack', 'C++']