Judge's Data for 2004 DSPC

Problem A:


8
1 1 1 1
3 7 15 20
1 2 5 5
2 8 15
1 3 7 8
4 1 2 4 20
1 3 3 7
4 2 10 20 21
2 3 5 6
20 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
2 2 2 2
5 1 3 5 7 9
1 1 5 7
4 3 8 20 30
1 4 5 9
6 1 2 3 7 30 1000

Problem B:

8
2 1 3
2 2 4
2 5 8
0
2 2 5
4 1 3 5 6
4 2 4 6 7
3 3 7 8
3 1 2 6
4 2 3 5 7
4 3 4 6 8
2 4 7
9
2 1 6
2 2 8
2 7 9
0
4 2 3 4 5
5 1 3 5 6 7
5 1 2 4 7 8
5 1 3 5 8 9
5 1 2 4 6 9
4 2 5 7 9
4  2 3 6 8
4 3 4 7 9
4 4 5 6 8
5
2 1 5
2 2 4
0
1 2
2 1 3
2 2 4
2 3 5
1 4
20
4 1 4 14 17
3 3 12 19
3 2 5 8
2 16 20
3 9 10 18
0
5 2 3 4 5 6
6 1 4 9 10 14 15
4 1 4 6 8
7 1 2 3 8 9 13 18
5 1 6 11 16 17
7 1 3 5 7 8 11 12
3 6 8 12
6 3 4 6 7 12 18
4 2 4 13 14
3 2 15 20
4 5 6 12 17
6 6 7 8 11 17 18
5 4 9 14 18 19
5 2 9 13 15 19
5 2 10 14 19 20
3 5 17 19
6 5 11 12 16 18 19
6 4 8 12 13 17 19
7 13 14 15 16 17 18 20
3 10 15 19
12
3 1 5 8
2 2 11
2 4 6
2 3 9
0
3 2 3 6
6 1 3 4 5 7 8
5 1 2 4 6 7
4 2 3 5 7
3 2 4 7
6 1 3 7 9 10 12
7 2 3 4 5 6 8 10
5 2 7 10 11 12
3 6 10 12
6 6 7 8 9 11 12
3 8 10 12
5 6 8 9 10 11
5
2 1 4
0
2 2 5
2 1 3
2 2 4
2 3 5
2 1 4
0

Problem C:

4 5
AAABA
A..BA
A...A
ACA.A
5 5
AA.AA
ABA.A
BAA.A
CCC.A
BAAA.
50 50
..................................................
..........AAAA....................................
..............AAAAAAAA............................
..................AA..............................
...................A..............................
...................A..............................
...................A..............................
...................AAAAAAAAAAAAA..................
............................AAAAAAAAA.............
........................AAAAAAAAAA................
...AAAAA...................AAAAAAAAAA.............
...AAAAA............AAAAAAAAAA....................
...AAAAA.....................AAAAAAAAAA...........
...AABBA.............AAAAAAAAAA.......AAAAAAAAAA..
...AA.AA........AAAAAAAAAA........................
...ADDDA...........AAAAAAAAAA.....................
...AAAAA.................AAAAA....................
...AAAAA.....................AAAAA................
...AAAAA...........AAAAA.AAAAA...AAAAA............
.......................AAAAA......................
.........AAAAA...........AAAAA....................
............AAAAA...AAAAA....AAAAA................
................AAAAA.............................
..................................................
..................................................
..................................................
..................................................
..................................................
..................................................
..................................................
..........BBBB.BBBB........BBBB...................
............BBBB.............BBBB.................
...............................BBBB...............
..................................................
..................................................
..................................................
..................................................
.....AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA..............
.....AAAAAA........................A..............
.....A.........AAAAA...............A..............
.....A.............AAAAA...........A..............
.....A................AAAAA........A..............
.....A.............................A..............
.....A.....AAAAA...................A..............
.....A.......AAAAA.................A..............
.....A........AAAAA................A..............
.....A.........AAAAA...............A..............
.....A.............................A..............
.....A.............................A..............
.....AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA..............
20 10
A.........
.A........
..A.......
...A......
....A.....
.....A....
......A...
.......A..
......A...
.....A....
....A.....
...A......
..A.......
...A......
....A.....
.....AA...
.......A..
....AAA...
..........
..........
0

Problem D:

8
1
111
1110011
11
1110011000011
111011100010001
1111001110000010000000000000001
11100010000001

Problem E:

5
2
1 2
4
0 2 3 5
4
2 3 6 11
4
0 5 8 12
6
1 2 3 20 50 100
4
70 50 100 200 
5
1 2 3 4 5
5
10 20 30 100 200
4
2 4 6 8
5
1 7 10 20 50

Problem F:

10
0 1
16 3
1 0
2 7
9 0
4 1
2 2
8 1
9 3
15 5
5
10 10
10 11
20 10
20 11
15 5
50
1 1
1 3
1 30
1 45
1 48
2 1
3 3
4 30
5 45
6 48
7 1
8 3
9 30
10 45
10 48
11 1
19 30
19 3
17 45
17 48
16 1
16 3
16 30
16 45
16 48
12 36
12 3
12 30
12 45
12 480
12 1
41 3
41 30
41 450
31 48
31 1
31 3
31 30
8 35
9 48
9 1
21 300
21 30
21 45
21 48
21 1
38 13
38 30
23 5
23 8
10
1 1
1 2
1 3
1 4
1 5
1 6
1 7
1 8
100 100
300 300
5
30 30
28 35
28 25
2 100
10 5
5
30 30
28 36
28 25
2 100
10 5
5
3 150
28 36
28 25
2 150
10 5
0