C++ Simple Sort Solution
\nclass Solution {\npublic:\n    static int m;\n    static bool compare(int a,int b){\n        if(abs(a-m)>abs(b-m)){\n            return true;\n        }else i
```\nclass Solution {\npublic:\n    static int m;\n    static bool compare(int a,int b){\n        if(abs(a-m)>abs(b-m)){\n            return true;\n        }else if(abs(a-m)==abs(b-m)){\n            if(a>b){\n                return true;\n            }\n        }\n        return 0;\n    }\n    vector<int> getStrongest(vector<int>& arr, int k) {\n        sort(arr.begin(),arr.end());\n        int n=arr.size();\n        m=arr[(n-1)/2];\n        sort(arr.begin(),arr.end(),compare);\n        vector<int>ans;\n        for(int i=0;i<k;i++){\n            ans.push_back(arr[i]);\n        }\n        return ans;\n    }\n};\nint Solution :: m;\n```
[]