SELECTION SORT
\n\nclass Solution {\npublic:\n    vector<int> sortArray(vector<int>& nums) {\n // Selection sort algorithm      \n        for( int i=0; i <nums.size()-1 ; i++)
```  \n\nclass Solution {\npublic:\n    vector<int> sortArray(vector<int>& nums) {\n // Selection sort algorithm      \n        for( int i=0; i <nums.size()-1 ; i++)\n        {\n            int min = i;\n            for( int j = i+1; j<nums.size(); j++)\n            {\n                if(nums[j] < nums[min])\n                {\n                    min = j; \n                }\n            }\n            swap(nums[min],nums[i]);\n        }\n        return nums;\n    }\n};\n\n```
[]