#include "cave.h"
int check[5000], s[5000], d[5000];
void exploreCave(int N) {
int i, open=0, x;
while(open>=0)
{
for(i=0 ; i<N ; i++)
if(check[i]==0)
{
s[i]=1-s[i];
x=tryCombination(s);
if(x==-1)
{
open=x;
break;
}
if(open!=x)
{
check[i]=1;
if(open<x)
{
open=x;
break;
}
}
else
s[i]=1-s[i];
}
}
for(i=0 ; i<N ; i++)
{
s[i]=1-s[i];
d[i]=tryCombination(s);
s[i]=1-s[i];
}
answer(s,d);
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Execution timed out |
2072 ms |
384 KB |
Time limit exceeded |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Execution timed out |
2058 ms |
448 KB |
Time limit exceeded |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Execution timed out |
2029 ms |
432 KB |
Time limit exceeded |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Execution timed out |
2045 ms |
256 KB |
Time limit exceeded |
2 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Execution timed out |
2050 ms |
432 KB |
Time limit exceeded |
2 |
Halted |
0 ms |
0 KB |
- |