C++ Solution without stack
Runtime: 20 ms, faster than 86.17% of C++ online submissions for Remove All Adjacent Duplicates In String.\nMemory Usage: 12.3 MB, less than 100.00% of C++ onli
Runtime: 20 ms, faster than 86.17% of C++ online submissions for Remove All Adjacent Duplicates In String.\nMemory Usage: 12.3 MB, less than 100.00% of C++ online submissions for Remove All Adjacent Duplicates In String.\n\n```\nstring removeDuplicates(string S) {\n        \n        string res;\n        \n        for(char ch : S)\n        {\n            if(!res.empty() && res[res.size() - 1] == ch) res.pop_back();\n            else res += ch;\n        }\n        \n        return res;\n    }
['C']