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 "routers.h"
#include <bits/stdc++.h>
using namespace std;
std::vector<int> find_routers(int l, int n, int q)
{
vector<int> cont;
cont.push_back(0);
int ultimo = 0, ultimoindex = 0, i = 0;
while (i <= l)
{
int a = use_detector(i);
if (a != ultimo)
{
cont.push_back(2 * i - 2 - cont[ultimoindex]);
ultimo = a;
ultimoindex = 2 * i - 2 - cont[ultimoindex];
i = ultimoindex;
}
i++;
}
return cont;
}
# | 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... |