# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
480064 | couplefire | Packing Biscuits (IOI20_biscuits) | C++17 | 1143 ms | 1051060 KiB |
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 <bits/stdc++.h>
using namespace std;
#define int long long
int count_tastiness(int x, vector<int> cnt){
vector<int> dp = {0}; int hi = 0;
for(int i = 0; i<cnt.size(); ++i){
hi += cnt[i]*(1<<i);
for(int j = 0, s = min((__int128)x*(1<<i), (__int128)2e18), m = dp.size(); j<m && dp[j]+s<=hi; ++j)
dp.push_back(dp[j]+s);
}
return dp.size();
}
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... |