# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
296635 | emil_physmath | Friend (IOI14_friend) | C++17 | 1 ms | 384 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 <algorithm>
#include <numeric>
#include "friend.h"
using namespace std;
using llong = long long;
enum Protocol { ME = 0, MY = 1, WE = 2 };
// Find out best sample
int findSample(int n, int a[], int host[], int prot[]){
if (count(prot + 1, prot + n, ME) == n - 1) {
}
if (count(prot + 1, prot + n, MY) == n - 1)
return accumulate(a, a + n, 0);
if (count(prot + 1, prot + n, WE) == n - 1)
return *max_element(a, a + n);
}
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... |