# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
540765 | kenjinemera | Knapsack (NOI18_knapsack) | C++14 | 1 ms | 212 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;
const int maxn = 10001, maxs = 2001;
long long dp[maxn][maxs][2];
int main() {
int s, n;
struct item
{
int v, w, k;
};
cin >> s >> n;
struct item arr[n+1];
// v -> value
// w -> weight
// k -> copies
for (int i = 1; i <= n; i++) {
int a, b, c;
cin >> a >> b >> c;
arr[i] = {a,b,c};
}
# | 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... |