Submission #863513

#TimeUsernameProblemLanguageResultExecution timeMemory
863513Cyber_WolfA Difficult(y) Choice (BOI21_books)C++17
5 / 100
124 ms1368 KiB
#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 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...