0
1
mirror of https://git.sb/baoshuo/OI-codes.git synced 2024-11-27 23:16:27 +00:00
OI-codes/BZOJ/1702/data/9.in

5002 lines
11 KiB (Stored with Git LFS)
Plaintext

5000 10
381
224
394
158
192
220
583
494
232
801
233
124
61
734
88
947
839
997
292
745
381
9
798
37
521
1004
376
20
106
888
135
371
424
240
922
658
590
778
171
606
867
515
683
792
620
253
641
823
271
499
762
1003
354
188
794
889
512
8
0
0
0
0
2
0
0
0
0
0
0
0
0
64
0
0
0
0
0
0
0
256
0
32
0
0
32
0
0
4
0
128
0
0
0
0
0
2
0
0
0
0
0
0
0
17
1
0
8
0
0
0
128
0
0
256
0
0
0
0
0
0
0
0
0
0
4
0
8
0
0
0
0
10
0
0
256
64
0
0
0
0
0
4
512
0
0
0
3
0
0
0
8
0
0
0
0
0
256
0
0
0
0
2
16
64
8
0
128
0
0
0
128
0
0
10
32
0
0
0
0
0
0
0
0
0
0
128
0
0
0
2
0
0
8
0
0
0
0
0
0
4
0
512
0
0
0
0
0
0
0
0
0
0
0
0
0
8
0
0
4
512
0
64
0
32
0
0
0
0
64
128
0
16
0
0
0
0
0
0
32
0
0
0
0
0
0
0
0
8
0
0
0
0
0
0
0
0
32
0
0
0
0
0
0
0
0
0
16
0
0
0
0
0
0
0
96
0
0
0
0
0
0
2
0
0
0
0
0
0
0
256
0
2
0
128
0
1
0
0
0
32
2
64
0
0
0
0
0
0
0
0
16
0
1
0
0
0
0
0
0
0
0
2
2
0
0
0
0
0
5
0
0
8
0
0
0
0
0
0
0
0
0
1
0
64
0
0
0
0
0
0
0
132
512
0
0
0
0
128
0
0
0
0
0
0
0
256
4
0
0
256
16
0
8
0
128
0
0
0
0
0
0
1
8
0
16
8
0
513
0
4
64
0
0
0
0
0
0
0
0
0
0
0
64
0
0
0
64
0
0
0
0
40
128
72
0
0
16
0
64
0
0
0
0
0
0
0
0
8
0
0
0
0
0
0
4
32
16
8
0
0
0
512
0
0
0
64
0
0
0
0
0
16
0
0
8
0
96
0
0
0
144
1
0
16
0
0
256
0
0
0
0
0
512
0
0
0
264
0
512
16
0
0
0
0
0
0
0
0
0
0
0
320
0
0
8
0
4
0
128
0
0
0
0
0
640
0
0
0
0
0
0
0
0
16
2
0
0
0
0
0
0
0
0
256
1
0
0
64
0
128
0
0
0
0
0
0
0
0
0
256
0
0
0
0
0
4
16
16
1
0
0
0
0
12
8
0
0
4
0
0
0
0
0
256
0
0
0
256
0
0
0
0
320
0
0
32
0
0
0
576
0
0
2
0
2
0
0
0
0
0
0
64
0
512
0
0
1
0
0
0
132
0
0
153
0
0
0
0
384
0
64
0
0
0
0
0
0
0
16
0
0
64
128
1
0
0
0
0
0
32
0
0
16
0
0
0
0
0
0
2
0
0
0
0
0
0
0
32
8
0
0
0
0
72
0
0
0
0
0
0
0
0
0
0
0
2
0
0
0
0
4
0
0
0
4
0
512
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
2
0
257
64
128
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
64
0
0
16
0
0
0
0
0
4
0
0
0
16
0
0
0
256
0
0
16
0
34
0
0
0
0
2
2
0
0
0
0
0
16
0
2
32
2
0
0
128
0
64
0
0
0
1
0
0
0
0
0
0
32
0
256
1
0
0
0
64
64
16
0
0
0
0
6
512
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
259
0
16
0
0
0
0
0
128
16
0
0
0
0
0
0
8
1
0
8
0
0
0
512
0
96
4
2
0
0
0
0
0
0
512
0
0
256
0
0
512
0
0
0
514
0
512
0
0
0
0
0
0
0
0
0
0
16
0
0
0
0
0
0
0
1
0
0
0
64
0
0
0
32
0
0
0
0
0
32
2
0
0
0
32
256
0
0
0
0
32
0
0
0
0
8
0
0
0
0
0
0
0
0
0
0
0
0
0
0
512
0
0
0
0
8
0
0
0
0
0
2
1
1
0
0
0
0
2
0
0
0
0
16
0
0
0
0
32
0
0
0
0
512
0
0
8
0
0
0
0
0
0
0
0
0
0
128
0
128
0
0
0
0
0
1
0
512
256
0
32
0
0
0
0
0
0
0
0
0
4
0
16
0
2
0
0
0
0
0
0
0
4
64
0
0
0
512
0
0
512
0
0
0
0
544
0
0
0
2
0
0
0
0
256
0
0
0
0
0
0
0
0
0
0
0
0
0
4
2
0
0
0
0
0
0
0
0
0
1
32
0
0
0
0
0
1
0
0
0
192
0
4
0
0
0
32
0
2
0
0
512
0
4
0
0
0
0
0
0
4
0
0
0
0
0
16
0
0
0
704
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
64
0
0
512
0
8
1
0
0
0
256
0
128
512
0
0
0
32
0
0
0
0
0
0
0
32
256
0
256
0
128
0
0
0
0
1
0
0
0
0
0
0
0
0
0
16
0
64
1
0
0
0
0
0
0
0
0
0
0
16
136
4
0
0
0
16
8
0
2
128
0
0
0
0
0
0
0
0
0
0
16
0
0
1
256
0
384
0
0
64
0
0
0
0
0
0
0
0
0
0
0
0
0
0
256
0
0
0
1
0
0
0
136
0
0
0
4
0
0
32
0
0
0
0
0
0
0
0
0
0
1
0
8
0
0
0
0
0
0
0
0
0
0
0
2
0
0
0
0
0
0
144
0
0
0
0
0
0
0
0
0
0
32
0
0
0
0
0
0
32
0
0
2
32
4
0
0
32
2
0
0
0
0
0
0
0
4
0
160
1
0
0
512
1
0
256
0
0
0
0
0
4
0
0
0
0
0
0
0
0
256
264
0
64
128
0
0
0
0
0
0
0
0
0
0
264
32
0
32
0
256
0
128
528
2
0
0
0
0
0
0
0
0
0
0
1
0
128
0
512
32
0
64
0
16
0
0
0
0
1
0
0
64
0
0
0
0
0
0
0
0
128
512
32
0
0
0
4
0
0
0
2
0
0
16
1
0
8
0
0
64
0
0
0
0
0
0
0
32
0
64
0
8
0
0
0
64
4
0
4
0
0
0
0
16
0
2
2
0
0
0
0
0
0
0
0
0
0
0
1
32
0
0
0
0
0
0
32
0
0
0
0
0
0
0
0
0
0
0
0
0
0
8
0
0
0
0
0
4
0
0
0
0
512
32
0
16
2
0
0
0
0
0
2
0
65
0
0
0
2
0
128
0
0
0
0
0
0
0
0
0
24
0
0
8
0
0
64
0
0
0
0
4
0
0
0
0
0
0
0
0
512
0
1
0
0
768
8
0
0
0
0
0
0
0
0
0
512
0
0
4
256
512
0
512
32
0
0
0
0
0
0
0
64
2
0
0
0
0
0
0
129
0
0
0
0
0
0
0
0
0
8
0
0
96
0
0
264
0
0
0
0
0
0
0
0
0
0
0
0
8
0
144
0
0
0
0
0
1
0
0
0
68
0
0
0
0
256
0
256
0
0
0
0
0
1
128
0
0
0
1
0
0
0
0
0
0
128
0
0
0
0
0
0
256
128
0
0
0
0
1
256
1
128
8
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
256
0
0
0
0
0
0
0
512
0
32
0
0
0
0
0
1
0
0
0
0
16
0
16
16
0
16
64
4
0
0
0
0
0
0
0
0
0
0
0
16
0
0
0
256
0
2
0
0
0
0
0
0
0
0
0
512
0
0
0
0
64
0
5
0
8
0
0
0
32
8
0
32
0
0
0
0
0
0
0
0
0
256
0
0
32
0
0
512
0
0
2
0
16
0
0
16
0
32
0
0
1
0
0
0
0
0
0
4
0
0
0
0
0
0
0
0
0
0
1
0
6
0
64
0
0
0
0
0
1
0
0
10
0
0
0
0
0
0
0
8
0
0
0
0
0
0
0
0
0
0
0
0
8
0
64
0
0
0
64
0
0
0
0
0
256
0
64
0
0
0
0
0
1
0
512
0
0
0
0
0
0
0
0
0
0
0
128
0
0
0
0
0
192
1
0
256
0
0
0
0
0
0
0
0
0
4
0
0
0
512
8
0
0
64
0
0
0
0
0
0
0
65
0
16
0
0
0
0
0
0
0
512
0
0
0
0
0
0
0
0
0
0
64
0
0
0
0
0
0
0
0
0
0
0
128
0
16
0
0
0
0
0
2
0
0
0
2
0
0
0
0
64
0
0
0
0
0
0
0
0
4
0
0
0
0
0
0
0
1
0
0
0
0
0
512
0
2
0
0
0
0
0
0
0
128
0
0
0
0
0
0
0
0
0
16
0
0
1
256
0
0
0
128
0
0
272
0
4
0
0
0
0
64
0
0
4
0
0
0
0
0
16
32
0
0
0
0
0
0
0
16
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
4
0
64
0
32
0
0
0
66
1
256
0
768
16
0
0
48
0
0
4
1
0
0
4
64
257
0
512
16
0
0
0
2
0
0
0
0
2
0
2
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
2
1
128
0
0
0
0
128
0
0
0
64
0
0
0
0
0
0
0
0
256
0
0
0
0
512
1
0
512
0
1
0
0
256
0
0
8
0
0
72
0
0
0
0
0
0
0
0
4
0
0
32
2
128
0
0
0
64
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
32
0
0
0
64
256
0
0
0
512
0
0
0
0
16
0
0
0
16
0
0
0
0
0
32
0
0
0
0
256
64
128
0
0
513
8
0
0
0
0
0
0
0
0
0
0
0
80
128
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
256
4
0
0
0
0
0
512
4
0
0
2
0
512
0
0
0
0
512
0
512
0
32
128
0
2
0
32
0
512
8
0
0
0
0
0
4
64
0
0
512
0
4
0
0
0
0
0
0
8
0
0
0
0
0
0
512
0
0
0
48
16
0
0
0
0
0
0
0
0
256
0
0
0
0
0
256
0
0
0
0
160
0
0
0
0
0
0
0
0
0
33
130
16
0
0
0
256
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
2
0
0
0
640
0
0
0
4
0
4
0
0
0
64
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
544
32
0
0
0
2
0
0
0
0
0
0
0
0
0
640
0
0
0
0
16
0
64
0
0
512
0
0
0
0
0
0
0
0
32
0
2
0
0
0
0
0
1
530
0
0
0
0
256
0
0
0
0
0
0
256
0
0
2
0
0
64
0
16
8
0
0
0
0
0
0
0
0
0
0
0
0
0
32
0
0
0
0
0
0
0
0
1
4
0
0
0
32
0
0
4
0
64
128
0
0
0
0
32
0
2
0
0
0
64
64
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
512
64
0
256
0
0
0
0
0
0
0
0
0
0
1
32
0
0
0
0
0
0
0
0
0
0
0
0
8
0
0
544
0
0
0
0
0
0
0
0
0
1
0
0
0
512
0
0
0
128
0
16
0
0
0
0
129
0
0
0
12
0
0
0
16
0
0
0
0
0
259
0
0
0
0
0
8
0
0
0
0
2
0
544
0
64
0
8
0
0
0
48
64
0
0
0
0
8
0
0
0
0
0
0
0
64
0
32
8
0
8
0
0
0
1
0
0
4
0
0
0
0
0
64
0
0
128
0
0
0
0
32
0
0
0
0
0
16
0
0
0
0
0
0
0
0
4
0
64
0
16
0
256
0
128
0
4
16
0
0
0
0
128
133
0
2
0
0
0
0
0
0
0
0
0
64
0
0
0
4
16
3
0
0
0
0
0
0
0
0
0
0
0
0
0
0
4
0
0
0
0
0
0
64
272
0
128
0
16
0
0
0
2
0
0
0
0
0
0
256
0
0
1
0
4
0
0
256
0
5
0
0
8
128
0
1
0
0
42
0
0
128
0
0
0
256
0
0
0
0
0
0
0
0
0
0
0
0
512
32
0
0
0
0
0
0
0
0
4
0
0
0
0
0
0
0
64
0
0
0
32
0
0
0
0
0
0
0
128
0
0
0
0
16
0
1
4
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
128
20
0
1
0
0
0
128
0
0
512
48
0
0
0
0
0
0
0
0
0
0
4
0
0
0
0
0
0
0
0
0
2
0
0
0
16
0
0
512
64
0
0
0
0
32
0
0
0
0
0
64
0
0
0
64
16
1
513
0
0
0
0
256
32
0
128
0
0
0
0
33
32
0
0
0
0
0
0
0
0
256
0
0
0
0
0
0
0
0
0
8
0
0
0
0
0
0
0
0
0
0
512
1
0
0
0
0
0
0
0
0
256
0
0
0
0
0
0
0
32
0
0
512
0
8
0
0
0
4
256
0
0
0
0
264
0
0
544
0
0
0
0
256
0
0
0
8
0
0
0
0
0
0
0
64
0
0
0
16
0
0
256
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
512
0
0
0
0
256
1
0
0
0
0
2
0
0
0
0
4
0
128
0
0
0
0
0
0
0
0
2
0
0
256
0
0
0
1
0
0
512
0
0
512
0
96
0
0
0
16
0
0
0
384
0
0
0
0
0
1
0
0
0
0
0
0
0
2
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
512
0
0
0
0
0
512
256
4
0
0
0
0
0
0
0
0
1
1
0
0
66
0
0
256
0
512
4
64
0
0
0
0
0
0
0
8
0
16
0
0
0
0
0
0
0
0
0
0
0
64
0
2
0
512
512
4
0
8
2
2
0
0
0
0
0
128
64
0
36
64
1
256
0
0
0
0
0
0
0
0
0
0
0
0
0
512
0
0
0
0
0
0
0
8
0
0
0
0
0
0
0
0
0
128
2
0
128
128
512
0
0
0
0
0
4
3
8
0
0
0
0
0
8
256
0
0
0
0
0
0
0
0
0
0
2
0
0
0
0
0
24
0
512
2
64
0
0
0
0
64
0
1
0
0
0
0
0
0
0
256
0
0
0
0
4
0
4
0
0
0
0
128
512
0
0
0
0
0
0
0
0
0
4
0
0
0
40
0
0
0
0
0
0
0
0
32
2
0
64
0
0
384
0
0
0
528
0
0
0
0
0
72
0
0
512
0
0
0
0
0
2
0
8
8
0
0
0
256
1
0
0
0
0
0
0
16
0
8
0
4
0
0
0
0
2
0
0
0
0
2
0
0
0
0
0
64
0
0
4
1
576
0
16
0
512
4
32
260
0
0
0
0
512
0
0
0
0
0
0
8
0
0
64
0
0
0
0
0
0
0
0
0
33
0
0
0
0
0
0
0
2
64
0
0
0
0
0
8
0
0
0
64
0
0
0
0
0
0
0
0
0
64
0
0
0
1
0
4
0
0
0
0
0
0
0
256
0
0
512
0
0
0
0
0
0
512
256
0
0
0
0
128
64
16
0
0
0
0
0
16
0
8
16
8
0
128
0
0
0
0
0
4
0
0
0
0
0
0
0
0
0
0
0
128
0
0
0
128
0
0
0
0
0
0
0
0
2
0
0
0
64
0
0
8
256
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
8
0
8
0
0
0
0
0
0
0
8
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
256
0
128
4
128
2
0
0
5
0
0
0
256
0
0
8
0
0
512
0
0
0
0
0
0
0
2
0
0
132
1
0
128
0
64
128
0
0
0
0
0
0
8
0
0
0
0
0
0
16
12
0
64
0
0
0
0
0
0
0
64
0
16
0
256
0
0
0
0
0
0
8
0
0
256
0
0
0
1
0
0
4
0
0
512
0
0
4
0
0
0
0
0
0
0
0
0
0
6
0
0
0
0
512
128
0
0
0
0
0
0
324
0
34
136
0
0
0
0
0
0
0
0
0
256
256
0
16
0
0
0
0
2
0
0
0
0
256
0
0
0
0
0
0
0
0
0
0
0
0
0
0
48
0
0
512
0
0
0
0
32
0
0
0
0
0
512
64
0
0
0
4
0
0
0
0
0
0
0
0
0
0
0
0
0
8
0
256
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
256
0
1
0
8
0
0
0
0
0
0
0
0
0
0
0
0
0
0
128
4
0
0
0
0
4
0
0
0
0
0
0
0
32
0
0
0
0
0
0
0
0
0
0
0
0
32
16
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
64
0
0
0
0
0
0
0
1
128
0
0
0
0
128
0
512
0
256
0
8
128
32
0
512
128
0
0
0
0
0
32
0
0
0
0
0
0
512
0
128
512
128
0
0
0
0
0
0
0
0
0
0
0
0
0
32
0
0
0
0
0
0
0
2
0
0
0
0
0
0
0
0
32
0
0
0
0
0
0
0
0
0
128
0
0
0
0
0
1
0
4
0
0
0
0
0
0
0
4
2
0
0
0
0
0
0
0
0
256
0
0
0
0
0
0
0
2
0
2
0
0
0
0
1
2
0
256
0
0
40
0
0
0
128
0
0
0
0
0
0
0
0
64
0
0
0
0
0
0
256
0
0
32
0
2
0
0
0
512
0
0
2
0
0
128
64
0
0
0
0
0
0
0
0
0
0
0
0
48
0
0
0
0
128
0
16
0
0
8
0
0
0
0
0
0
0
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0
0
4
0
0
0
0
0
0
0
0
0
0
128
0
64
0
0
0
0
0
0
128
0
8
0
0
256
0
16
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
128
0
256
0
0
32
0
0
16
0
0
0
4
0
0
256
0
0
0
8
0
0
0
0
0
0
256
512
256
0
0
0
0
272
4
0
256
0
0
0
2
0
0
0
0
0
0
0
16
0
0
0
0
2
0
0
256
0
0
0
72
0
0
64
0
0
0
0
0
512
0
0
32
0
0
0
0
2
16
0
0
0
0
0
0
0
0
0
0
0
0
16
0
0
2
0
0
0
512
0
0
2
256
32
0
0
32
0
0
0
4
0
0
0
0
0
0
128
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
128
0
0
0
0
8
0
0
2
0
0
512
0
0
0
1
256
0
0
0
128
0
0
0
64
0
0
8
0
0
0
0
0
0
8
0
0
0
0
0
0
0
0
0
8
0
0
0
128
0
0
16
0
0
0
0
16
0
0
0
0
0
0
0
0
0
0
64
1
0
0
0
0
0
0
16
8
0
0
0
0
0
0
0
0
0
0
0
0
32
0
0
0
0
16
0
0
0
0
0
0
0
512
0
0
0
0
0
0
0
0
0
0
0
32
0
0
0
16
0
0
0
0
0
0
0
0
0
0
0
0
0
4
8
0
0
0
8
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
4
0
0
0
0
0
0
0
0
0
128
256
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
32
0
0
512
0
4
0
0
0
0
0
513
301
674
874
822
49
194
948
1019
705
252
231
713
421
440
929
947
1014
82
514
382
130
830
261
414
208
133
177
993
49
432
451
235
826
0
375
166
425
245
737
851
952
616
471