-
Notifications
You must be signed in to change notification settings - Fork 1
/
input
5000 lines (5000 loc) · 26.3 KB
/
input
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
3711
-1434
1793
611
9745
6977
7163
8640
-3210
-6021
-3404
-6977
-5746
8756
5559
-9619
-1866
-9562
7336
-3121
-2412
-7053
-6967
-4095
7454
3949
1055
7965
1308
4022
359
-6990
1006
-8119
-7148
-5458
-6618
9992
-3646
1793
4309
-6088
6522
-5626
773
6529
-5447
7121
63
-7056
-4580
-5384
-7206
5015
-5324
2437
-931
-3531
-5958
-8531
0
9725
3551
9580
9777
4239
-3800
-3889
4798
1715
-1807
448
-3838
5468
3435
4854
9925
-2548
-4662
1641
1823
-3224
359
8642
-8134
8477
397
6050
-6056
-2329
247
2919
-8241
-8198
-7070
508
3345
-7737
-3458
-5900
-2956
9992
-3929
-1389
7747
5159
-9927
8393
5146
4737
-7176
8154
477
8966
-8203
-5948
-1525
-6351
4007
8372
-8985
388
6133
518
1267
9773
2714
4947
2161
1223
-5259
6322
-5186
3864
-5344
-2420
-1242
6960
-2377
8871
1518
-9880
3367
6834
-3829
7001
941
5185
3002
-3084
-7070
-4173
9754
900
6195
2130
-5964
-7878
-3
7151
5948
7665
7895
-9371
327
4869
152
-6958
-6296
8194
8123
7439
-2254
-16
-751
-6009
-3955
9470
-7791
4588
-5378
9495
2220
-1858
1527
1963
9943
-7271
-8554
4164
152
1492
-8801
-4645
2536
1122
9611
5725
9810
8110
3892
-1580
7627
1540
4122
-7754
-2150
9716
7127
9455
-6339
-5646
-2025
-2586
5523
2424
-6795
5478
242
9484
-1920
3024
9282
3932
-7070
-3920
-7596
227
4513
1143
2130
-2601
1074
-4291
5726
230
8708
3423
-8941
1027
-3335
2054
-1598
4935
9076
9098
-9976
-1600
-9612
-7150
9448
-3430
6262
-5112
-9738
8903
6967
3989
7919
-9361
-8157
2838
6866
9267
-4897
-8796
-6670
-2613
997
995
6519
-5600
-1548
8620
-3014
-1061
3967
192
583
-3798
-2890
-2239
6047
6233
-5972
1568
875
9710
1915
8620
7033
232
3833
-1292
-5711
-6597
-715
-4065
-8022
1581
-7646
3755
7937
1949
-4269
7803
-5900
-3000
-2908
8306
-5777
649
-6533
7804
-1301
-8806
4138
4022
2923
9501
3746
-1680
1029
-2401
8457
-3335
1826
9502
2492
-895
-8447
6751
-4796
-2519
-2649
5269
5864
-176
-5903
-9547
7806
-3982
9102
2374
-8895
5452
-5065
-6263
6123
4055
9971
-195
959
-2045
-3237
-9170
-7621
-1455
-7843
8085
5801
-646
7119
-1301
301
7729
3904
-4593
7799
4339
7264
611
2734
6154
3862
2713
-9613
-866
3188
9082
-2484
6786
-522
8062
-234
-7845
-9660
1297
5789
-2066
7857
-933
-2178
7206
-6504
4055
-4807
-8287
-8065
3043
-9367
-7066
2888
-547
-7988
3681
2135
-7083
-4887
9593
629
-9389
4778
-8152
4703
4526
5965
5523
-970
1699
-4042
-650
-8718
-2099
-2156
-4250
4823
-1267
1054
9660
-1510
9011
6465
-8139
-769
4040
3500
3360
-7299
3766
635
-7621
5493
8574
-7727
-4625
-2266
1380
7632
-4705
6430
8313
2205
4779
-9803
6928
9110
-6164
-6503
6285
-4434
-38
4934
-5710
7322
-8140
-5492
-1237
-8029
-281
274
6660
7603
-6250
-107
2023
553
-1339
6742
-9890
3069
8624
-8671
4634
506
-5903
7875
-8332
-8603
-9607
-433
-7442
-5899
-8164
4245
-811
-9127
-7596
-4576
-9453
-6504
-2406
7283
5984
7702
2991
-8341
-5793
-2952
-9463
867
1082
8990
4741
-6387
-67
3772
3932
2446
9514
4070
7338
-4634
-8774
579
-7621
-3342
9672
4092
-422
-6056
4502
-281
-2633
1616
7322
1641
-1866
2188
-9607
-4265
-3395
2112
7505
-3274
3926
5881
192
9355
-8975
-9799
5615
4961
5862
-8966
9161
-6568
7096
-9547
5168
4871
5105
7509
-405
8359
-61
5177
-9230
4772
-4277
8922
6834
-1224
-8463
-9651
7449
-3979
2919
5817
-168
-6770
-2367
2220
-2373
-1798
-6918
-2319
-9646
3677
3783
-824
-5958
991
9581
626
-5542
-168
-4514
8471
9315
-5256
8625
1951
8054
1467
-1692
7030
-9811
4351
-4503
-3983
3625
5593
9576
7627
-2095
4053
-458
-522
-1838
-6086
-7957
-3073
-7032
-2301
-1879
-8940
-3929
-5143
9198
5136
-3503
-221
569
3258
8969
5137
4466
1198
-1875
-7001
-8401
-9628
-4376
6368
6899
-6998
-6268
-5578
850
7758
-2836
-3617
5199
5857
-915
-4008
9964
-2042
-4576
702
4350
-7378
388
-5676
-2485
2237
-8245
-3345
3039
-9985
626
-6423
9599
-8799
1249
-9322
-6598
5068
-3124
-4186
1393
7608
-4406
-7980
-588
-6723
28
-6056
1908
-7477
-2009
-4253
8781
7499
4501
1728
5461
604
-735
9829
-2972
9601
-7072
6440
-9937
-3971
6880
2082
9716
6638
1172
14
5047
-7490
-9798
4022
6741
5366
-8177
4941
1765
9473
-8059
-9316
9990
-4018
-6433
-7806
-3095
-2871
3495
-7505
9062
-6506
4805
6931
9992
-5401
5894
5628
2473
1826
-257
-5631
1538
5608
-7503
6411
-9362
-3265
-6574
-4470
-7029
1915
-9432
-1257
1948
1131
-3303
5011
517
-6743
-599
-6787
-359
9250
-7051
993
5770
9742
-1802
2514
5247
8838
-3919
-5189
8633
1211
2514
-2848
415
7978
-8183
6431
4257
-3348
2552
4703
372
73
2872
9685
7138
-1985
479
8810
7952
-8495
2764
-945
3249
1141
-3655
-1048
1503
-5303
518
3755
-5365
-7401
-5034
7222
7108
1213
5847
-8774
7389
7066
3532
8243
-8940
-5596
-2759
-396
262
2765
6705
-1114
2942
8483
7333
639
8388
-2879
6452
-1414
3180
-9251
-8615
7207
323
5863
9321
8551
415
3285
9107
-2295
-4844
1194
3020
7871
6974
-3971
-1879
730
6215
5238
2375
-2887
-7060
3696
2288
7999
1008
-2604
-12
1572
-9604
-6650
4753
5562
-8574
6115
-5266
-3122
4575
6406
-9340
-3121
5
-7167
2984
5484
6640
-2095
-582
-1572
-3949
-3198
-2734
-678
-7252
-931
5301
357
9194
-3664
3194
1949
-409
3983
5376
691
7083
-4065
-3167
-1577
7589
6096
-2066
9945
423
-1591
7136
3371
-8023
8236
-2649
584
-9400
4925
3767
-330
5121
-7338
-4365
8840
6691
1018
1092
5364
7778
-690
-176
5411
5873
4854
-8838
-4143
-4521
-1137
-9568
3975
-2602
-7136
676
626
4196
5565
3024
1623
-1081
-8027
-8253
-8941
7800
4077
-4431
8085
2124
-2527
8478
4817
-6855
-5003
9819
-4330
5057
7358
915
-5578
9566
7048
1831
-3216
-9236
-4071
-7120
8054
9425
2345
1313
6317
7739
-8791
-7157
3937
2519
-4901
1980
644
2935
7185
4961
5301
9346
6224
-990