#include <iostream>
#include <vector>
#include <algorithm>
#include <set>
#include <map>
#include <cstring>
#include <cmath>
#include <functional>
#include "molecules.h"
using namespace std;
vector<int> find_subset(int l, int u, vector<int> w) {
vector<int> answer;
int cur = 0;
for (int i = 0; i < (int)w.size(); ++i) {
if (cur < l) {
cur += w[i];
answer.emplace_back(i);
}
}
if (l <= cur && cur <= u) answer.clear();
return answer;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
5 ms |
256 KB |
sum of weights should be in [10..12] but it is 9 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
5 ms |
256 KB |
sum of weights should be in [302..304] but it is 351 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
5 ms |
256 KB |
sum of weights should be in [10..12] but it is 9 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
5 ms |
256 KB |
sum of weights should be in [10..12] but it is 9 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
5 ms |
256 KB |
sum of weights should be in [10..12] but it is 9 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
5 ms |
256 KB |
sum of weights should be in [10..12] but it is 9 |
2 |
Halted |
0 ms |
0 KB |
- |