# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
823846 | irmuun | Computer Network (BOI14_network) | C++17 | 70 ms | 7892 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;
#define ll long long
#define pb push_back
#define ff first
#define ss second
#define all(s) s.begin(),s.end()
#define rall(s) s.rbegin(),s.rend()
void findRoute(int N,int a,int b){
vector<int>route;
int dist=ping(a,b);
dist++;
vector<int>v(dist);
for(int i=1;i<=N;i++){
if(a==i||b==i) continue;
int x=ping(a,i),y=ping(b,i);
x++,y++;
if(x+y==dist){
v[x-1]=i;
}
}
v[dist-1]=b;
for(int i=0;i<dist;i++){
travelTo(v[i]);
}
}
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... |