# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
76647 | Vasiljko | Computer Network (BOI14_network) | C++14 | 172 ms | 47680 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 <bits/stdc++.h>
#include "network.h"
using namespace std;
typedef long long ll;
const ll MOD = 1e9+7;
const int N = 1005;
vector<int>v[N];
void findRoute(int n,int a,int b){
int dist=ping(a,b);
for(int i=1;i<=n;i++){
if(i!=a&&i!=b)v[ping(i,b)].push_back(i);
}
int cur=a;
dist--;
while(dist>=0){
int i=0;
while(ping(v[dist][i],cur)!=0)i++;
cur=v[dist][i];
dist--;
travelTo(cur);
}
travelTo(b);
}
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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |