# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
760053 | jk410 | Bulb Game (FXCUP4_bulb) | C++17 | 1 ms | 212 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
#include "bulb.h"
using namespace std;
int n;
vector<int> l, r;
vector<int> ans;
void update(int lx, int rx, int v) {
ans[lx] += v;
ans[rx + 1] -= v;
}
int dfs(int cur, int f, int s, int cnt) {
if (cur == -1)
return 0;
if (cur == -2) {
if (f == -1)
return 0;
else if (s == -1) {
if (cnt == n)
return 0;
update(0, n - 1, 1);
update(f, f, 1);
return 1;
}
update(f, f, 1);
update(s, s, 1);
return 0;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |