# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
12249 | pro0331 | 전선 연결하기 (GA9_wire) | C++98 | 0 ms | 4016 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 <stdio.h>
int n;
int a[600000];
char ans[600001];
char check(int s)
{
int t = a[s];
bool high = true, low = true;
int i;
for (i = s+1; a[i] != t && (high || low); i++) {
if (ans[i] == '^')
high = false;
else if (ans[i] == 'v')
low = false;
}
if (high == false && low == false)
return 0;
if (high) {
ans[s] = ans[i] = '^';
} else {
ans[s] = ans[i] = 'v';
}
return 1;
}
int main()
{
int i;
# | 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... |