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>
#include "books.h"
#ifdef CYBER
#include "grader.cpp"
#endif
#define lg long long
using namespace std;
void solve(int N, int K, long long A, int S)
{
vector<lg> v(N);
for(int i = 1; i <= N; i++)
{
v[i] = skim(i);
}
vector<int> ans;
for(int i = 1; i <= N && ans.empty(); i++)
{
for(int j = i+1; j <= N && ans.empty(); j++)
{
for(int k = j+1; k <= N && ans.empty(); k++)
{
if(v[i]+v[j]+v[k] >= A && v[i]+v[j]+v[k] <= 2*A)
{
ans.push_back(i);
ans.push_back(j);
ans.push_back(k);
break;
}
}
}
}
if(ans.empty()) impossible();
answer(ans);
}
# | 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... |