# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
33773 | dqhungdl | Bali Sculptures (APIO15_sculpture) | C++14 | 103 ms | 10060 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;
const int64_t MAX=41;
int64_t n,A,B,a[2005],F1[2005];
bool Free[2005][2005],F[2005][2005],Free1[2005];
int64_t f1(int64_t i,int64_t mask)
{
if(Free1[i]==true)
return F1[i];
F1[i]=1e9;
Free1[i]=true;
if(i>n)
return F1[i]=0;
for(int64_t t=i; t<=n; t++)
{
int64_t tmp=a[t]-a[i-1];
if((mask|tmp)==mask)
F1[i]=min(F1[i],f1(t+1,mask)+1);
}
return F1[i];
}
bool f(int64_t i,int64_t j,int64_t mask)
{
if(Free[i][j]==true)
return F[i][j];
Free[i][j]=true;
if(j>B)
# | 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... |