For this Question: You have N kilograms of fruits with you and M types of polybags to put the fruits into. The holding capacity of the i<sup>th</sup> polybag is p<sub>i</sub>. Find the minimum number of polybags required to carry all N kilograms of fruits.The first line contains two integers N and M.
The second line contains M space-separated integers.

<b>Constraints:</b>
1 &le; N &le; 10<sup>12</sup>
1 &le; M &le; 10<sup>5</sup>
1 &le; p<sub>i</sub> &le; 10<sup>8</sup>Print the minimum number of polybags required to carry all N-kilograms of fruits.Sample Input:
10 4
4 9 8 2

Sample Output:
2

<b>Explaination:</b>
We can carry fruits in polybag 1 and polybag 3. This will give us a total capacity of 4 + 8 = 12 kilograms which is more than that required to carry the fruits., I have written this Solution Code: #include <bits/stdc++.h>
using namespace std;
#define int long long

signed main(){
    int n, m;
    cin >> n >> m;
    vector<int> a(m);
    for(auto &i : a) cin >> i;
    sort(a.rbegin(), a.rend());
    int ans = 0, cur = 0;
    for(int i = 0; i < m; i++){
        ans++;
        cur += a[i];
        if(cur >= n){
            break;
        }
    }
    cout << ans;
}, In this Programming Language: C++, Now tell me if this Code is compilable or not?