이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
// from duckindog wth depression
#include<bits/stdc++.h>
using namespace std;
//#define LOCAL
#ifndef LOCAL
#include "molecules.h"
#endif // LOCAL
struct T {
int a, b;
T(int aa, int bb) : a(aa), b(bb) {}
};
vector<int> find_subset(int l, int u, vector<int> w) {
if (w[0] > u) return {};
int sum = 0;
int x = u / w[0];
for (int i = 0; i < min(x, int(w.size())); ++i) sum += w[i];
if (l <= sum && sum <= u) {
vector<int> answer;
for (int i = 0; i < x; ++i) answer.push_back(i);
return answer;
}
return {};
}
#ifdef LOCAL
int32_t main() {
cin.tie(0)->sync_with_stdio(0);
if (fopen("duck.inp", "r")) {
freopen("duck.inp", "r", stdin);
freopen("duck.out", "w", stdout);
}
}
#endif // LOCAL
# | 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... |