Minimum Diameter Tree
1085D1700· expert1s256 MB⌨ stdin/stdout
Examples
Sample 1of 3
Input
4 31 21 31 4
Output
2.000000000000000000
Sample 2of 3
Input
6 12 12 32 55 45 6
Output
0.500000000000000000
Sample 3of 3
Input
5 51 22 33 43 5
Output
3.333333333333333333
58%
1085D.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)
loading graph engine…