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, the main problem you meet now is Time Exceeded. And the exit code of your program is -9, which should be 0.
Please double check your code to solve this problem and try again.
Your Answer
1186252026 1000000200 1184773609 1103389613 1064705627 1250702914 1312112545 107 1060744033 1219849185 1178021472 1000000300 1019867293 1000000587 1272017114 1426148511 1371664461 1000000199 1184558601 1000000055 1077030867 1351118349 1390639471 1000000372 1386888735 51 1000000548 1193520239 1099067154 1427615615 1052376551 1467088908 1426342738 1187113109 1000000089 1101132030 1000000465 1000000660 1358437943
JOJ Answer
1186250486 999998660 1184772069 1103388073 1064704087 1250701374 1312111005 107 1060742493 1219847645 1178019932 999998760 1019865753 999999047 1272015574 1426146971 1371662921 999998659 1184557061 999998515 1077029327 1351116809 1390637931 999998832 1386887195 51 999999008 1193518699 1099065614 1427614075 1052375011 1467087368 1426341198 1187111569 999998549 1101130490 999998925 999999120 1358436403 1482452413 1330533837 999998664 1043420470 1202439011 1132531564 1017208530 1038284167 105 1428605974 16 1064844957 1130828884 1201346007 1284177250 1192996750 1104767276 999998575 1418746486 56 1096717536 210 999998989 1164234882 999998586 1215215825 999999017 999998816 1395881531 999998564 999999064 1385459346 1454829507 1099288476 999998926 999998576 999998399 1124707438 1104970990 1326641633 1209627850 999998851 1036754881 1277062867 1263352539 1044007867 1189621246 1236627700 999998438 1102149627 1421078632 1161897341 999998879 1247759883 1484090889 1264300482 61 1156588426 1007725521 1245995914 1005947576 1