# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
65186 | spencercompton | Zalmoxis (BOI18_zalmoxis) | C++14 | 544 ms | 83568 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 <bits/stdc++.h>
using namespace std;
int n, k;
void f(int now){
if(now==0 || k==0){
cout << " " << now;
return;
}
k--;
f(now-1);
f(now-1);
}
int main(){
cin >> n >> k;
vector<pair<int, int> > li;
for(int i = 0; i<n; i++){
int x;
cin >> x;
li.push_back(make_pair(i,x));
}
vector<pair<int, int> > cur;
cur = li;
vector<int> add[n];
int use = 0;
for(int i = 0; i<30; i++){
vector<pair<int, int> > nxt;
nxt.push_back(cur[0]);
for(int j = 1; j<cur.size(); j++){
int bef = nxt.back().second;
int now = cur[j].second;
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |