제출 #432605

#제출 시각아이디문제언어결과실행 시간메모리
432605daniel920712도시들 (IOI15_towns)C++14
0 / 100
24 ms964 KiB
#include "towns.h" #include <iostream> using namespace std; int all[205][205]={0}; int hubDistance(int N, int sub) { int i,j,k,ans=0,a,b,c; for(i=0;i<N;i++) { for(j=i+1;j<N;j++) all[i][j]=all[j][i]=getDistance(i,j); } for(i=0;i<N;i++) { for(j=i+1;j<N;j++) { for(k=j+1;k<N;k++) { a=all[i][j]; b=all[i][k]; c=all[j][k]; ans=max(ans,(a+b+c)/2-a); ans=max(ans,(a+b+c)/2-b); ans=max(ans,(a+b+c)/2-c); } } } return ans; }

컴파일 시 표준 에러 (stderr) 메시지

towns.cpp: In function 'int hubDistance(int, int)':
towns.cpp:5:28: warning: unused parameter 'sub' [-Wunused-parameter]
    5 | int hubDistance(int N, int sub)
      |                        ~~~~^~~
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...