This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include"molecules.h"
#include"bits/stdc++.h"
using namespace std;
using ll = long long;
vector<int> find_subset(int l, int u, vector<int> w) {
vector<pair<ll, int>> v;
for (int i = 0; i < (int)w.size(); ++i) {
v.push_back({w[i], i});
}
vector<int> ret;
sort(v.begin(), v.end());
ll sum = 0;
int i = 0;
while (sum < l) {
sum += v[i].first;
ret.push_back(v[i].second);
++i;
}
return ret;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |