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"
using namespace std;
void solve(int n, int k, long long a, int s) {
long long x[n];
for (int i = 0; i < n; i++)
x[i] = skim(i + 1);
for (int i = 0; i < n; i++) {
long long sum = 0;
for (int j = i; j < i + k; j++)
sum += x[j];
if(sum >= a && sum <= 2 * a){
vector<int> t;
for(int j = i; j < i + k; j++)
t.emplace_back(j + 1);
answer(t);
return;
}
}
impossible();
}
# | 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... |