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;
int64_t max_weights(int n, int m, vector<int> x, vector<int> y, vector<int> w)
{
int64_t l_sum = 0;
int64_t r_sum = 0;
for (int i = 0; i < m; i++)
if (x[i] == 0)
l_sum += w[i];
else if (x[i] == 1)
r_sum += w[i];
else
assert(false);
return max(l_sum, r_sum);
}
# | 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... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |