Keep Consonants, Sort Vowels || C++
 # Intuition  \n\n\n# Approach\nSeparate vowels, sort them, and reinsert them into the original string while preserving the consonants\' positions.\n\n\n# Compl
<!-- # Intuition -->\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\nSeparate vowels, sort them, and reinsert them into the original string while preserving the consonants\' positions.\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n- $$O(n*log(n))$$\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n- $$O(n)$$\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution {\npublic:\n    bool isVowel(char c){\n    string vows="aeiouAEIOU";\n        for(auto i:vows){\n            if(c==i) return 1;\n        }\n        return 0;\n    }\n    string sortVowels(string s) {\n        string vowels="";\n        int l=s.length();\n        for(int i=0;i<l;i++){\n            if(isVowel(s[i])){\n                vowels.push_back(s[i]);\n            }\n        }\n        sort(vowels.begin(),vowels.end());\n        int p=0;\n        for(int i=0;i<l;i++){\n            if(isVowel(s[i])){\n                s[i]=vowels[p++];\n            }\n        }\n        return s;\n    }\n};\n```
['C++']