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

0
2147483647
4014
1323
2147483647
1265
2147483647
8216
3711
2147483647
2147483647
1382
1778
817
8212
8126
4666
133
2559
2147483647
7017
4741
5499
2147483647
1562
4636
2147483647
6747
0
8424
2822
1481
8012
-4
5025
10458
2147483647
1217
3199
8525
1750
4422
1277
3011
78
9306
4470
5057
6694
12246
2544
8309
1508
2147483647
7939
7592
0
7468
1952
7419
7588
6656
7300
693
8809
6916
270
8756
2072
4877
-10
205
2401
1740
4694
-7
13438
5036
468
8840
785
8419
16543
8951
0
710
9097
440
3725
12130
6017
17760
9801
9221
9236
11023
1934
4651
1254
7010
10691
1725
7298
7711
6088
576
2675
3196
7429
8007
415
7883
0
7746
2497
7071
1300
1108
892
331
685
4781
-31
5292
405
-69
135
2155
3597
408
8294
780
883
6575
1200
6032
8824
1326
7355
911
0
3408
7982
2211
-23
1803
1242
1596
-21
880
9
1316
842
1046
1230
4508
1319
2187
1691
1794
7486
2111
8013
1318
74
1414
2026
7493
0
2955
3326
767
2535
2357
344
3068
763
2595
-5
279
2117
1814
3139
67
3216
618
49
2826
859
8088
1393
149
1489
2101
7568
75
0
3401
842
2610
2432
-67
3143
838
2670
70
354
2192

JOJ Answer

-10
181
45
-57
205
349
5
909
175
4
292
229
-48
1324
-6
319
10
169
1084
1358
-17
801
154
172
-57
308
213
1173
-25
698
-83
45
375
340
275
1817
276
846
205
551
750
1301
280
988
-80
1041
-120
692
219
378
244
-17
274
343
47
1173
607
104
1240
379
845
260
-37
777
361
-40
-10
2011
-22
373
112
514
135
292
452
-120
167
111
-18
-37
1382
192
867
-114
232
405
-17
328
-19
244
-10
81
185
-68
281
-183
301
1195
-116
332
927
110
759
61
1101
-67
519
1376
229
1763
5
-65
288
212
280
344
110
1772
348
171
1259
152
434
420
-64
1426
-48
139
24
779
218
-116
801
45
106
1324
867
1358
480
232
210
154
595
864
1324
212
24
405
292
311
1318
1108
106
234
1022
252
41
88
1698
126
5
577
179
607
85
801
2337
618
-111
373
-102
498
-173
252
1
132
-32
-215
98
-51
6
435
128
466
93
739
226
-48
-46
162
1088
642
18
279
108
74
455
861
1181
88
555
9
896
493
413
232
121
76
257
493
7
184
1719
240
-20
279
27
30
24
55
219
1028
-69
761
24
1656
-65
857
252
1832
132