QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#503225#6455. Fancy Antiquesxiaowuc1AC ✓1868ms3836kbC++173.4kb2024-08-03 17:02:222024-08-03 17:02:27

详细

Test #1:

score: 100
Accepted
time: 0ms
memory: 3828kb

input:

3 3 2
1 30 2 50
2 70 3 10
3 20 1 80

output:

60

result:

ok single line: '60'

Test #2:

score: 0
Accepted
time: 0ms
memory: 3836kb

input:

3 3 1
1 30 2 50
2 70 3 10
3 20 1 80

output:

-1

result:

ok single line: '-1'

Test #3:

score: 0
Accepted
time: 0ms
memory: 3524kb

input:

3 40 20
1 30 2 50
2 70 3 10
3 20 1 80

output:

60

result:

ok single line: '60'

Test #4:

score: 0
Accepted
time: 0ms
memory: 3528kb

input:

100 40 20
1 30 2 50
2 70 3 10
3 20 1 80
4 4053052 4 7662462
5 6987579 5 9821219
6 588704 6 3169368
7 1855889 7 9935232
8 2445527 8 7208464
9 3245826 9 153464
10 6724394 10 3773003
11 138078 11 3902451
12 6323938 12 7726520
13 4002855 13 2468305
14 3780209 14 8406910
15 8274996 15 1897226
16 9687072 ...

output:

-1

result:

ok single line: '-1'

Test #5:

score: 0
Accepted
time: 0ms
memory: 3552kb

input:

100 40 20
1 30 2 50
2 70 3 10
3 20 1 80
4 4053052 4 7662462
5 6987579 5 9821219
6 588704 6 3169368
7 1855889 7 9935232
8 2445527 8 7208464
9 3245826 9 153464
10 6724394 10 3773003
11 138078 11 3902451
12 6323938 12 7726520
13 4002855 13 2468305
14 3780209 14 8406910
15 8274996 15 1897226
16 9687072 ...

output:

424060800

result:

ok single line: '424060800'

Test #6:

score: 0
Accepted
time: 1868ms
memory: 3756kb

input:

89 39 23
27 8551750 28 4374011
34 2965066 35 7844878
27 2111972 28 1665806
28 3749537 29 6515434
31 497849 32 143180
12 5324267 13 7310878
23 2331829 24 9979737
21 6603822 22 6443539
27 4465135 28 6396697
33 4684116 34 3389916
24 355923 25 721115
28 1581991 29 6140478
35 8606514 36 2499216
6 3352537...

output:

348996868

result:

ok single line: '348996868'

Test #7:

score: 0
Accepted
time: 131ms
memory: 3616kb

input:

96 40 40
1 8221853 2 3170193
1 8030475 3 3458952
1 4144653 4 3760155
1 7419250 5 2275065
1 9081504 6 7268473
2 6769576 3 8143204
2 5795462 4 2170579
2 9392026 5 4076453
2 1809050 6 7302618
3 7891949 4 3596357
3 4876372 5 904475
3 8427767 6 4358918
4 195497 5 8799318
4 4121147 6 7763464
5 1953967 6 5...

output:

331115359

result:

ok single line: '331115359'

Test #8:

score: 0
Accepted
time: 0ms
memory: 3612kb

input:

96 40 22
1 8221853 2 3170193
1 8030475 3 3458952
1 4144653 4 3760155
1 7419250 5 2275065
1 9081504 6 7268473
2 6769576 3 8143204
2 5795462 4 2170579
2 9392026 5 4076453
2 1809050 6 7302618
3 7891949 4 3596357
3 4876372 5 904475
3 8427767 6 4358918
4 195497 5 8799318
4 4121147 6 7763464
5 1953967 6 5...

output:

-1

result:

ok single line: '-1'

Test #9:

score: 0
Accepted
time: 1ms
memory: 3756kb

input:

100 40 23
11 8755933 8 609057
36 5017083 5 8008163
33 5634965 10 7419250
19 855609 31 9881521
20 7941242 2 8328247
24 5411913 17 2170579
18 8646081 11 3993054
37 2754282 14 7530521
24 256814 15 4876372
38 6105468 13 242517
1 3501847 9 5586064
14 3477422 19 7763464
23 2881109 24 7906949
2 2752095 28 ...

output:

371683294

result:

ok single line: '371683294'

Test #10:

score: 0
Accepted
time: 1847ms
memory: 3832kb

input:

100 40 30
39 8218237 29 356073
27 1548047 5 4350753
32 1187974 34 4490418
15 3176003 40 8241648
2 73016 1 7847261
2 9514888 3 1069732
11 969953 22 3196290
11 8718361 3 1046946
8 4760917 20 8009044
20 7746712 19 8298064
40 4135968 15 8791389
34 3414712 36 9458497
3 2285998 7 183118
16 782742 18 78215...

output:

353127128

result:

ok single line: '353127128'

Test #11:

score: 0
Accepted
time: 174ms
memory: 3828kb

input:

94 40 36
6 6916127 17 4226024
29 3416758 23 1600591
29 7551254 23 2718010
27 7900302 16 5284376
7 2685530 2 8122090
20 851026 23 3873903
37 4775399 34 4636604
21 1454188 13 6356570
5 8360815 14 123549
28 4399165 21 8920544
18 7422520 11 5688295
27 211114 36 6648457
19 3812693 24 2613179
2 9121428 34...

output:

318303772

result:

ok single line: '318303772'

Test #12:

score: 0
Accepted
time: 1ms
memory: 3816kb

input:

100 40 22
11 8755933 8 609057
36 5017083 5 8008163
33 5634965 10 7419250
19 855609 31 9881521
20 7941242 2 8328247
24 5411913 17 2170579
18 8646081 11 3993054
37 2754282 14 7530521
24 256814 15 4876372
38 6105468 13 242517
1 3501847 9 5586064
14 3477422 19 7763464
23 2881109 24 7906949
2 2752095 28 ...

output:

-1

result:

ok single line: '-1'

Test #13:

score: 0
Accepted
time: 1235ms
memory: 3600kb

input:

100 40 39
11 8755933 8 609057
36 5017083 5 8008163
33 5634965 10 7419250
19 855609 31 9881521
20 7941242 2 8328247
24 5411913 17 2170579
18 8646081 11 3993054
37 2754282 14 7530521
24 256814 15 4876372
38 6105468 13 242517
1 3501847 9 5586064
14 3477422 19 7763464
23 2881109 24 7906949
2 2752095 28 ...

output:

298761771

result:

ok single line: '298761771'

Test #14:

score: 0
Accepted
time: 194ms
memory: 3588kb

input:

39 40 20
1 54 2 107
1 113 3 122
2 117 4 64
2 76 5 56
3 19 6 31
3 46 7 95
4 27 8 45
4 42 9 44
5 40 10 51
5 95 11 39
6 97 12 59
6 121 13 122
7 28 14 41
7 40 15 49
8 74 16 92
8 121 17 32
9 24 18 28
9 36 19 19
10 12 20 51
10 102 21 105
11 109 22 41
11 73 23 12
12 73 24 109
12 50 25 44
13 54 26 110
13 10...

output:

1913

result:

ok single line: '1913'

Test #15:

score: 0
Accepted
time: 263ms
memory: 3524kb

input:

39 40 20
29 108 33 46
29 123 8 46
33 48 37 69
33 118 40 1
8 3 10 85
8 6 2 15
37 56 39 97
37 111 25 68
40 42 17 43
40 48 15 110
10 32 4 98
10 35 3 93
2 74 11 69
2 71 32 11
39 10 35 44
39 30 5 11
25 35 28 77
25 1 12 91
17 61 7 83
17 113 38 55
15 48 36 79
15 15 30 62
4 20 20 26
4 104 21 90
3 2 19 86
3 ...

output:

1454

result:

ok single line: '1454'

Test #16:

score: 0
Accepted
time: 7ms
memory: 3540kb

input:

40 40 21
29 763 33 1053
33 762 8 1010
8 625 37 1117
37 707 40 120
40 452 10 549
10 716 2 1145
2 971 39 484
39 309 25 591
25 543 17 614
17 128 15 958
15 1173 4 1155
4 1017 3 478
3 1002 11 81
11 934 32 328
32 871 35 250
35 613 5 21
5 93 28 275
28 751 12 21
12 227 7 44
7 374 38 966
38 528 36 414
36 579...

output:

21227

result:

ok single line: '21227'

Test #17:

score: 0
Accepted
time: 0ms
memory: 3788kb

input:

100 15 11
6 310 13 161
10 539 12 1235
10 617 10 707
12 224 5 1074
9 282 8 344
8 893 5 484
13 1182 3 158
15 499 3 34
2 788 10 1173
3 210 5 995
5 827 15 1203
6 584 1 328
4 1126 1 761
12 978 4 1112
9 1214 11 751
4 531 2 185
1 1209 1 181
15 870 5 414
9 793 1 549
8 944 12 445
7 772 15 578
8 678 1 632
5 1...

output:

46623

result:

ok single line: '46623'

Test #18:

score: 0
Accepted
time: 0ms
memory: 3600kb

input:

100 15 10
6 310 13 161
10 539 12 1235
10 617 10 707
12 224 5 1074
9 282 8 344
8 893 5 484
13 1182 3 158
15 499 3 34
2 788 10 1173
3 210 5 995
5 827 15 1203
6 584 1 328
4 1126 1 761
12 978 4 1112
9 1214 11 751
4 531 2 185
1 1209 1 181
15 870 5 414
9 793 1 549
8 944 12 445
7 772 15 578
8 678 1 632
5 1...

output:

-1

result:

ok single line: '-1'

Test #19:

score: 0
Accepted
time: 3ms
memory: 3592kb

input:

42 34 17
3 5348414 2 702835
33 3218203 24 1694510
29 8699821 4 5832968
25 3466232 23 1548862
5 7592262 23 7927599
16 9733611 1 7266596
5 3228809 15 2674817
27 9781175 34 9884447
5 7267340 9 53085
2 8686767 27 4377296
3 6261202 27 3388065
10 5195497 10 2214792
29 7088240 34 1671541
19 3022417 6 27932...

output:

147126573

result:

ok single line: '147126573'

Test #20:

score: 0
Accepted
time: 0ms
memory: 3808kb

input:

29 1 1
1 142618 1 280979
1 1236414 1 5157068
1 4132214 1 1589725
1 6456090 1 2680390
1 2480364 1 6133908
1 3118509 1 2204386
1 6258496 1 78812
1 3379943 1 3223009
1 5144625 1 4475098
1 1638179 1 2181229
1 2482999 1 5987235
1 1268089 1 1787805
1 1926337 1 6015720
1 2040322 1 4927670
1 3533020 1 39062...

output:

63957213

result:

ok single line: '63957213'

Test #21:

score: 0
Accepted
time: 0ms
memory: 3816kb

input:

55 29 3
3 995413 2 4956941
1 4651374 15 3784136
18 6759580 22 3687402
20 275939 5 1150169
13 5551046 12 330672
1 1003836 6 2294739
24 7364879 12 7841635
15 4534071 19 6531280
15 3180572 25 2857912
21 3984719 6 1653938
11 3606648 14 3229431
14 741144 13 380151
18 4938857 4 1646509
11 7566161 15 23066...

output:

-1

result:

ok single line: '-1'

Test #22:

score: 0
Accepted
time: 0ms
memory: 3772kb

input:

46 12 8
5 6620275 3 6797527
2 5490077 4 1979830
9 4034593 7 4862757
9 5462326 9 3295665
12 2254742 7 655866
2 6046267 2 4633361
8 5431278 2 5969775
12 192586 11 4620866
11 6283398 11 806852
12 6434248 5 4969555
4 3610559 5 4237478
10 1833225 11 180541
5 1221469 2 2793189
6 1341942 4 4546833
5 346370...

output:

133758758

result:

ok single line: '133758758'

Test #23:

score: 0
Accepted
time: 0ms
memory: 3780kb

input:

51 13 12
3 2945398 5 4254708
7 2897148 11 2731532
6 1817170 12 3944864
12 6069411 10 6451807
3 4263190 4 4749693
6 3563545 11 1688813
10 108996 6 2592265
6 2369266 5 4495271
8 5313067 6 5300378
3 455766 3 6536378
9 1300426 12 626241
7 3763375 11 404797
10 824844 3 3408298
8 65075 4 2025032
7 6418480...

output:

105878721

result:

ok single line: '105878721'