C++(Using Stack- 100% faster)
Please Upvote if you like the solution!\n\n    class Solution {\n    public:\n    int minAddToMakeValid(string s) \n    {\n        stack st;//create a Stack\n  
**Please Upvote if you like the solution!**\n\n    class Solution {\n    public:\n    int minAddToMakeValid(string s) \n    {\n        stack<char> st;//create a Stack\n        \n        for(int i=0;i<s.size();i++)\n        {\n            if(s[i]==\'(\')//whenever their is open bracket insert on stack\n                st.push(\'(\');\n            else \n            {\n                if(!st.empty() && st.top()==\'(\')//if their is open bracket on the top of stack and stack is not empty, then pop\n                    st.pop();\n                else\n                    st.push(\')\');//otherwise push closing bracket on stack\n            }\n        }\n        return st.size();//atlast return stack size\n    }\n    };
['String', 'Stack', 'C', 'C++']