Record Case Detail

Notes

This function is in beta test. Please help improve it in the issues here.

Stderr


        

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

616
769
287
503
554
358
697
931
794
789
371
551
821
746
558
431
806
387
474
308
574
911
322
696
918
599
325
328
626
528
912
559
553
593
384
399
493
677
335
541
789
548
574
845
917
110
619
341
87
445
827
297
454
756
550
290
909
295
915
123
565
727
871
890
97
777
445
748
531
369
588
634
656
667
670
939
530
240
739
680
395
667
571
431
808
355
342
583
633
475
180
260
637
352
834
272
529
586
802
741
455
167
189
481
569
567
892
579
613
942
347
252
437
53
317
661
412
661
869
902
333
527
914
320
516
507
608
711
803
650
235
297
789
536
353
942
954
948
628
840
273
562
277
838
191
597
796
521
423
629
336
246
145
791
540
748
508
868
388
824
877
861
282
857
257
589
503
733
165
796
792
785
790
466
531
714
537
150
229
820
671
913
530
581
773
650
225
585
810
229
615
283
784
899
391
417
312
555
657
733
463
292
652
527
749
315
547
721
693
411
310
771
513
409
875
440
594
577
266
427
610
708
421
137
470
730
636
872
602
821
363
740
355
629
436
840
426
724
772
958
696
439
591
744
878
228
544
128
876
431
705
176
369
513
206
829
214

JOJ Answer

Invalid graph. Exiting.