Self explanatory Java Solution
class Solution {\n\n    public boolean asteroidsDestroyed(int mass, int[] ast) {\t\n        Arrays.sort(ast);\n        long x=(long)mass;\n        for(long i : 
class Solution {\n\n    public boolean asteroidsDestroyed(int mass, int[] ast) {\t\n        Arrays.sort(ast);\n        long x=(long)mass;\n        for(long i : ast)\n        {\n            if(x<i)\n                return false;\n            \n            x+=i;\n        }\n        return true;\n    }\n}
['Sorting', 'Java']