Java stream&sorting solution
java\nimport static java.lang.Math.*;\nimport static java.util.Arrays.*;\nimport static java.util.Comparator.*;\n\nclass Solution {\n    public int[] getStronge
```java\nimport static java.lang.Math.*;\nimport static java.util.Arrays.*;\nimport static java.util.Comparator.*;\n\nclass Solution {\n    public int[] getStrongest(int[] arr, int k) {\n        sort(arr);\n        var median = arr[(arr.length - 1) / 2];\n        return stream(arr)\n            .boxed() // need to box/unbox as `sorted()` is not overloaded for `IntStream`\n            .sorted(comparingInt((Integer n) -> abs(n - median)).thenComparingInt(n -> n).reversed())\n            .mapToInt(n -> n)\n            .limit(k)\n            .toArray();\n    }\n}\n```
['Sorting', 'Java']