Submission #863495

#TimeUsernameProblemLanguageResultExecution timeMemory
863495Ahmed_SolymanA Difficult(y) Choice (BOI21_books)C++14
5 / 100
160 ms1244 KiB
#include <bits/stdc++.h> #include "books.h" using namespace std; typedef long long ll; // // --- Sample implementation for the task books --- // // To compile this program with the sample grader, place: // books.h books_sample.cpp sample_grader.cpp // in a single folder and run: // g++ books_sample.cpp sample_grader.cpp // in this folder. // void solve(int n, int k, long long a, int s) { // TODO implement this function vector<ll>v; for(int i=1;i<=n;i++){ v.push_back(skim(i)); } for(int i=0;i<n;i++){ for(int j=i+1;j<n;j++){ for(int k=j+1;k<n;k++){ ll sum=v[i]+v[j]+v[k]; if(sum>=a && sum<=a*2LL){ answer({i+1,j+1,k+1}); } } } } impossible(); }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...