Notes
This function is in beta test. Please help improve it in the issues
here.
Hints
Your answer may be identical to the JOJ answer in the first several lines.
However, you will still get Wrong Answer because the complete output may be longer and there might be errors in the future lines.
Please double check your code to solve this problem and try again.
Your Answer
29134 27999 790 28014 1963 279 31601 42033 798 10628 24298 668 39444 19338 970 32157 6533 565 25925 5432 831 32072 13473 417 5337 45740 17 37087 37080 996 7597 29301 201 28429 13318 329 41924 30897 559 7999 24933 485 2472 3845 994 25770 18893 810 35384 34071 985 13011 25454 273 18 25959 651 24554 49402 767 13241 28160 51 26239 39611 570 13326 36657 881 19664 32142 871 22192 10172 492 49811 42004 271 33873 10262 504 4646 40752 170 33398 34995 788 4878 36699 313 47601 23418 132 47210 21482 105 33158 48532 801 13871 3620 714 18046 45258 800 8225 32609 306 12951 33374 983 30618 23621 463 3497 34070 236 30982 47515 480 45602 27082 495 35850 37942 617 6000 6604 814 10390 27822 520 8649 41209 426 15517 25641 852 34285 41238 936 35499 24172 800 32512 44707 169 25676 3289 996 39004 48525 778 48170 1794 747 14857 8586 26 44219 31201 285 15994 190 89 9393 5271 583 40649 36160 119 36190 12180 632 33343 20922 278 7458 24069 24 15860 41854 87 1601 6065 574 14371 39123 250 9182 39483 355 44583 31057 122 25257 36201 513 4265
JOJ Answer
Shortest path length is 5176 The graph is not a DAG No MST exists!