Tree Weights
1844G3000· legendary gm5s256 MB⌨ stdin/stdout
#bitmasks#constructive algorithms#data structures#dfs and similar#implementation#math#matrices#number theory#trees
Examples
Sample 1of 3
Input
51 21 32 42 531 41 59 26
Output
3110188
Sample 2of 3
Input
31 21 318 18
Output
-1
Sample 3of 3
Input
93 14 15 92 65 35 89 79 2236 205 72 125 178 216 214 117
Output
3141592653589793
58%
1844G.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)
loading graph engine…