# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
74223 | 2018-08-30T13:41:41 Z | MKopchev | Towns (IOI15_towns) | C++14 | 1000 ms | 500 KB |
#include<bits/stdc++.h> #include "towns.h" using namespace std; const int nmax=1e2+42; int dist[nmax][nmax]; int hubDistance(int N,int sub) { for(int i=0;i<N;i++) for(int j=i+1;j<N;j++) { int d=getDistance(i,j); dist[i][j]=d; dist[j][i]=d; } int p=0,q=0; for(int i=0;i<N;i++) for(int j=i+1;j<N;j++) if(dist[p][q]<dist[i][j])p=i,j=q; int mini=1e9; for(int k=0;k<N;k++) { int n1=(dist[p][q]+dist[k][p]-dist[k][q])/2; mini=min(mini,max(n1,dist[p][q]-n1)); } return mini; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 1081 ms | 376 KB | Time limit exceeded |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 380 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 1055 ms | 456 KB | Time limit exceeded |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 456 KB | Output isn't correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Execution timed out | 1061 ms | 456 KB | Time limit exceeded |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 2 ms | 500 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |