# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
112050 | Eug1ena | Bali Sculptures (APIO15_sculpture) | C++14 | 192 ms | 632 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;
using lint = long long;
int N, A, B;
vector<lint> sum{0};
lint notbit = 0;
lint dp[105][105];
bool minimum(int now, int cnt){
if(now == N){
return (A <= cnt && cnt <= B);
}else if(dp[now][cnt] != -1){
return dp[now][cnt];
}
int ans = false;
for(int i = now + 1; i <= N; i++){
if(((sum[i] - sum[now]) & notbit) == 0){
ans |= minimum(i, cnt + 1);
}
}
return dp[now][cnt] = ans;
}
int dp2[2020];
int minimum2(int now){
if(now == N){
Compilation message (stderr)
# | 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... |