# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
547036 | ala2 | Split the sequence (APIO14_sequence) | C++14 | 461 ms | 20056 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>
#define int long long
#define F first
#define S second
#define pb push_back
#define B begin()
#define E end()
using namespace std;
int n,K;
const int inf=-1e15;
int p[1001000];
int a[1001000];
int dp[1012][1012];
int H;
int mul(int i,int j)
{
return (p[j]-p[i]+a[i])*(p[n-1]-p[j]);
}
int f(int i,int k)
{
if(k<0)
return inf;
if(i>=n-1)
return 0;
if(dp[i][k]!=-1)
return dp[i][k];
int mx=0;
for(int j=i;j<n-1;j++)
{
# | 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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |