Submission #987437

#TimeUsernameProblemLanguageResultExecution timeMemory
987437mateuszwesDetecting Molecules (IOI16_molecules)C++17
0 / 100
1 ms348 KiB
#include <bits/stdc++.h> typedef long long ll; typedef unsigned long long ull; #define F first #define S second #define pb push_back #define pq priority_queue #define pl pair<ll,ll> #include "molecules.h" using namespace std; constexpr int debug = 0; vector<int> find_subset(int l, int u, vector<int> w){ vector<int> ans; ll sum = 0; sort(w.rbegin(), w.rend()); for(auto k: w){ if(k <= u){ sum += k; ans.pb(k); } if(sum >= l) break; } return ans; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...