# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
150156 | 욱방켜!! (twitch.tv/wookje) (#200) | Bulb Game (FXCUP4_bulb) | C++17 | 2 ms | 380 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 "bulb.h"
#include <bits/stdc++.h>
std::vector<int> L, R;
int FindWinner(int T, std::vector<int> L, std::vector<int> R){
int N = L.size(), c, n, t;
std::vector<int> t1, t2;
::L=L; ::R=R;
for(int i=0;i<N;i++) {
bool valid=true;
for(c=0;c>=0;c=c==i ? R[c]:L[c]) {
for(n=c==i ? L[c]:R[c];n>=0;n=L[n]);
if(n==-2) valid=false;
}
if(valid && c==-1) return 1;
}
return 0;
}
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... |