C++ Short Greedy Solution
\nclass Solution {\npublic:\n    int minElements(vector<int>& nums, int limit, int goal) {\n        long sum = 0;\n        for (int num : nums) {\n            s
```\nclass Solution {\npublic:\n    int minElements(vector<int>& nums, int limit, int goal) {\n        long sum = 0;\n        for (int num : nums) {\n            sum += num;\n        }\n        long target = goal - sum;\n        return target % limit == 0 ? abs(target / limit) : abs(target/limit) + 1;\n    }\n};\n```
[]