# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1138115 | Aliyyiakbar | Detecting Molecules (IOI16_molecules) | C++20 | 0 ms | 328 KiB |
#include "molecules.h"
#include "bits/stdc++.h"
using namespace std;
bool in(const int &x, const int &lf, const int &rg)
{
return lf <= x && x <= rg;
}
vector<int> find_subset(int l, int r, vector<int> w)
{
vector<int> res;
int tot = 0;
for (int i = 0; i < (int)w.size(); ++i)
{
tot += w[i];
res.push_back(i);
if (in(tot, l, r))
{
return res;
}
}
res.clear();
return res;
}
Compilation message (stderr)
# | 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... |