Submission #774109

#TimeUsernameProblemLanguageResultExecution timeMemory
774109Trumling동굴 (IOI13_cave)C++14
13 / 100
2058 ms428 KiB
#include "cave.h" #include <bits/stdc++.h> using namespace std; typedef long long ll; #define pb push_back #define F first #define S second #define enter cout<<'\n'; #define INF 99999999999999999 #define MOD 1000000007 #define all(x) x.begin(),x.end() //tryCombination void exploreCave(int N) { int s[N]={ },d[N]; ll i=tryCombination(s); bool no[N]={ }; while(i!=-1) { for(int j=0;j<N;j++) { if(no[j]) continue; s[j]=s[j]^1; int pos=tryCombination(s); s[j]=s[j]^1; if(pos>i) { i=pos; no[j]=1; break; } if(pos<i) no[j]=1; } } for(int j=0;j<N;j++) { s[j]=s[j]^1; int pos=tryCombination(s); s[j]=s[j]^1; d[j]=pos; } answer(s,d); }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...