# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
308893 | dangle1907 | K blocks (IZhO14_blocks) | C++14 | 215 ms | 80760 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;
typedef long long LL;
#define fi first
#define se second
const int MAXN=1+1e5;
const int inf=1+1e9;
LL n,k,f[110][MAXN],a[MAXN];
deque<pair<LL,LL> > q;
int main()
{
#define TASK "ABC"
//freopen(TASK ".inp","r",stdin);
//freopen(TASK ".out","w",stdout);
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cin>>n>>k;
for(int i=1; i<=n; ++i)
{
cin>>a[i];
}
for(int i=1; i<=k; ++i)
{
for(int j=0; j<=n; ++j)
{
f[i][j]=inf;
}
}
f[1][0]=0;
for(int i=1; i<=n; ++i) f[1][i]=max(f[1][i-1],a[i]);
# | 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... |