# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
724979 |
2023-04-16T12:07:36 Z |
AndrijaM |
Bank (IZhO14_bank) |
C++14 |
|
0 ms |
212 KB |
#include <bits/stdc++.h>
using namespace std;
const int maxn=1e5+10;
int n;
int k;
int x[maxn];
int sum[maxn];
vector<int>ans;
int f(int idx,int kol,vector<int>v)
{
if(kol==0)
{
ans=v;
return sum[n-1]-sum[idx];
}
int rez=0;
for(int i=idx+1;i<n-1;i++)
{
vector<int>pom;
pom=v;
pom.push_back(i);
if(idx==-1)
{
int koj=kol-1;
if(koj>=0)
rez=max(rez, f(i,koj,pom)*sum[i]);
}
else
{
int koj=kol-1;
if(koj>=0)
rez=max(rez, f(i,koj,pom)*(sum[i]-sum[idx]));
}
}
return rez;
}
int main()
{
return 0;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
0 ms |
212 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
0 ms |
212 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
0 ms |
212 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
0 ms |
212 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |