Easy Solution || Using Min Heap || C++
\n\n# Code\n\nclass Solution {\npublic:\n    vector<int> sortArray(vector<int>& nums) {\n        \n        priority_queue<int,vector <int>,greater<int>> p;\n\n 
\n\n# Code\n```\nclass Solution {\npublic:\n    vector<int> sortArray(vector<int>& nums) {\n        \n        priority_queue<int,vector <int>,greater<int>> p;\n\n         for(auto i:nums){\n             p.push(i);\n         }\n         int i=0;\n         while(!p.empty()){\n            nums[i++]=p.top();\n            p.pop();\n         }\n         return nums;\n    }\n};\n```
['Array', 'Divide and Conquer', 'Heap (Priority Queue)', 'C++']