C++ Simplest solution | Two pointer | Sorting
\nvector<int> getStrongest(vector<int>& arr, int k) {\n        sort(arr.begin(), arr.end());\n        int len = arr.size();\n        int median = arr[(len-1)/2]
```\nvector<int> getStrongest(vector<int>& arr, int k) {\n        sort(arr.begin(), arr.end());\n        int len = arr.size();\n        int median = arr[(len-1)/2];\n        vector<int> ans;\n        int li = 0, ri = len-1;\n        while(ans.size()<k && li<=ri){\n            if(abs(arr[ri]-median)>=abs(arr[li]-median)) {\n                ans.push_back(arr[ri]);\n                ri--;\n            }\n            else{\n                ans.push_back(arr[li]);\n                li++;\n            }\n        }\n        return ans;\n    }\n```\n\nLogic: Strongest element will be either side of shortest array (beacuse absolute difference will be maximum there)\n\nComment if you want Video Explaination for solution.\nI hope it helps!
['Two Pointers', 'C', 'Sorting', 'C++']