# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
106872 | brcode | Cave (IOI13_cave) | C++14 | 434 ms | 640 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 <iostream>
#include <map>
#include "cave.h"
using namespace std;
const int MAXN = 5010;
int m1[MAXN];
int s[MAXN];
int curr;
bool check(int l,int r){
for(int i=l;i<=r;i++){
if(m1[i]){
continue;
}
s[i] = 1-s[i];
}
int hold = tryCombination(s);
for(int i=l;i<=r;i++){
if(m1[i]){
continue;
}
s[i] = 1-s[i];
}
if(hold>curr||hold==-1){
return true;
}
return false;
}
void exploreCave(int N){
int d[N+1];
# | 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... |