Short || Clean || Java
java []\nclass Solution {\n    public int maxScore(int[] nums) {\n        long sum = 0;\n        int i=nums.length-1;\n        Arrays.sort(nums);\n        if(nu
```java []\nclass Solution {\n    public int maxScore(int[] nums) {\n        long sum = 0;\n        int i=nums.length-1;\n        Arrays.sort(nums);\n        if(nums[nums.length-1] == 0)    return 0;\n        while(i >= 0){\n            sum += nums[i--];\n            if(sum <= 0) return nums.length-i-2;\n        }\n        return nums.length;\n    }\n}\n```
['Java']