QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#505631#3477. Restaurant Bribesxiaowuc1AC ✓29ms10792kbC++172.2kb2024-08-05 06:33:062024-08-05 06:33:06

詳細信息

Test #1:

score: 100
Accepted
time: 1ms
memory: 6232kb

input:

10 1 1
1 2
1 3

output:

276.000000000

result:

ok found '276.0000000', expected '276.0000000', error '0.0000000'

Test #2:

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

input:

100000 0 0

output:

0.000000000

result:

ok found '0.0000000', expected '0.0000000', error '-0.0000000'

Test #3:

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

input:

100 4950 0
1 2
1 3
1 4
1 5
1 6
1 7
1 8
1 9
1 10
1 11
1 12
1 13
1 14
1 15
1 16
1 17
1 18
1 19
1 20
1 21
1 22
1 23
1 24
1 25
1 26
1 27
1 28
1 29
1 30
1 31
1 32
1 33
1 34
1 35
1 36
1 37
1 38
1 39
1 40
1 41
1 42
1 43
1 44
1 45
1 46
1 47
1 48
1 49
1 50
1 51
1 52
1 53
1 54
1 55
1 56
1 57
1 58
1 59
1 60
1 ...

output:

0.000000000

result:

ok found '0.0000000', expected '0.0000000', error '-0.0000000'

Test #4:

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

input:

100 4950 1
1 2
1 3
1 4
1 5
1 6
1 7
1 8
1 9
1 10
1 11
1 12
1 13
1 14
1 15
1 16
1 17
1 18
1 19
1 20
1 21
1 22
1 23
1 24
1 25
1 26
1 27
1 28
1 29
1 30
1 31
1 32
1 33
1 34
1 35
1 36
1 37
1 38
1 39
1 40
1 41
1 42
1 43
1 44
1 45
1 46
1 47
1 48
1 49
1 50
1 51
1 52
1 53
1 54
1 55
1 56
1 57
1 58
1 59
1 60
1 ...

output:

9800.000000000

result:

ok found '9800.0000000', expected '9800.0000000', error '0.0000000'

Test #5:

score: 0
Accepted
time: 2ms
memory: 7344kb

input:

100 4950 2
1 2
1 3
1 4
1 5
1 6
1 7
1 8
1 9
1 10
1 11
1 12
1 13
1 14
1 15
1 16
1 17
1 18
1 19
1 20
1 21
1 22
1 23
1 24
1 25
1 26
1 27
1 28
1 29
1 30
1 31
1 32
1 33
1 34
1 35
1 36
1 37
1 38
1 39
1 40
1 41
1 42
1 43
1 44
1 45
1 46
1 47
1 48
1 49
1 50
1 51
1 52
1 53
1 54
1 55
1 56
1 57
1 58
1 59
1 60
1 ...

output:

5800.000000000

result:

ok found '5800.0000000', expected '5800.0000000', error '0.0000000'

Test #6:

score: 0
Accepted
time: 2ms
memory: 6296kb

input:

100 4950 100
1 2
1 3
1 4
1 5
1 6
1 7
1 8
1 9
1 10
1 11
1 12
1 13
1 14
1 15
1 16
1 17
1 18
1 19
1 20
1 21
1 22
1 23
1 24
1 25
1 26
1 27
1 28
1 29
1 30
1 31
1 32
1 33
1 34
1 35
1 36
1 37
1 38
1 39
1 40
1 41
1 42
1 43
1 44
1 45
1 46
1 47
1 48
1 49
1 50
1 51
1 52
1 53
1 54
1 55
1 56
1 57
1 58
1 59
1 60
...

output:

0.000000000

result:

ok found '0.0000000', expected '0.0000000', error '-0.0000000'

Test #7:

score: 0
Accepted
time: 9ms
memory: 9832kb

input:

100000 99999 1
1 2
1 3
1 4
1 5
1 6
1 7
1 8
1 9
1 10
1 11
1 12
1 13
1 14
1 15
1 16
1 17
1 18
1 19
1 20
1 21
1 22
1 23
1 24
1 25
1 26
1 27
1 28
1 29
1 30
1 31
1 32
1 33
1 34
1 35
1 36
1 37
1 38
1 39
1 40
1 41
1 42
1 43
1 44
1 45
1 46
1 47
1 48
1 49
1 50
1 51
1 52
1 53
1 54
1 55
1 56
1 57
1 58
1 59
1 6...

output:

99998900.000000000

result:

ok found '99998900.0000000', expected '99998900.0000000', error '0.0000000'

Test #8:

score: 0
Accepted
time: 23ms
memory: 10612kb

input:

100000 99999 99999
1 2
1 3
1 4
1 5
1 6
1 7
1 8
1 9
1 10
1 11
1 12
1 13
1 14
1 15
1 16
1 17
1 18
1 19
1 20
1 21
1 22
1 23
1 24
1 25
1 26
1 27
1 28
1 29
1 30
1 31
1 32
1 33
1 34
1 35
1 36
1 37
1 38
1 39
1 40
1 41
1 42
1 43
1 44
1 45
1 46
1 47
1 48
1 49
1 50
1 51
1 52
1 53
1 54
1 55
1 56
1 57
1 58
1 59...

output:

0.000000000

result:

ok found '0.0000000', expected '0.0000000', error '-0.0000000'

Test #9:

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

input:

100 99 99
1 2
1 3
1 4
1 5
1 6
1 7
1 8
1 9
1 10
1 11
1 12
1 13
1 14
1 15
1 16
1 17
1 18
1 19
1 20
1 21
1 22
1 23
1 24
1 25
1 26
1 27
1 28
1 29
1 30
1 31
1 32
1 33
1 34
1 35
1 36
1 37
1 38
1 39
1 40
1 41
1 42
1 43
1 44
1 45
1 46
1 47
1 48
1 49
1 50
1 51
1 52
1 53
1 54
1 55
1 56
1 57
1 58
1 59
1 60
1 6...

output:

1.000000000

result:

ok found '1.0000000', expected '1.0000000', error '0.0000000'

Test #10:

score: 0
Accepted
time: 13ms
memory: 7748kb

input:

10000 92104 100
1 8289
1 6033
1 7153
1 6599
1 3658
1 4907
1 9034
1 638
1 6865
1 3031
1 4408
1 3993
1 7355
1 8828
1 6078
2 3777
2 9924
2 5575
2 4298
2 1676
2 7312
2 5956
2 3029
2 5423
2 544
2 795
2 4368
2 5470
2 3296
2 737
2 7388
2 6694
2 9704
2 1903
2 8883
2 9782
2 8953
2 9468
3 484
3 7826
3 8041
3 ...

output:

207438.666666667

result:

ok found '207438.6666667', expected '207438.6666667', error '0.0000000'

Test #11:

score: 0
Accepted
time: 13ms
memory: 7744kb

input:

10000 92104 100
1 7745
1 4034
1 1412
1 2511
1 8976
1 6101
1 1423
1 3864
1 4121
1 859
1 4316
1 3101
1 9827
1 9318
1 9064
1 4458
1 9199
1 7157
1 6010
1 5184
1 4925
1 2560
2 9538
2 3020
2 9094
2 2055
2 4482
2 9002
2 5836
2 6824
2 2673
2 6515
2 4980
2 2262
2 984
2 5664
2 5542
3 6018
3 6888
3 9225
3 9387...

output:

186435.000000000

result:

ok found '186435.0000000', expected '186435.0000000', error '0.0000000'

Test #12:

score: 0
Accepted
time: 13ms
memory: 7760kb

input:

10000 92104 100
1 2113
1 3460
1 9321
1 8199
1 5106
1 3273
1 8429
1 3371
1 9164
1 6733
1 6450
1 6485
1 5206
1 1221
1 7162
1 3852
1 6165
2 217
2 3655
2 1874
2 6189
2 4683
2 5427
2 7469
2 6734
2 5523
2 1534
2 753
2 626
2 8819
2 1268
2 7983
2 1438
2 3804
2 2493
2 8459
2 3037
3 2823
3 519
3 6504
3 5738
3...

output:

86710.666666667

result:

ok found '86710.6666667', expected '86710.6666667', error '0.0000000'

Test #13:

score: 0
Accepted
time: 10ms
memory: 7740kb

input:

10000 92104 100
1 3009
1 5794
1 4811
1 1774
1 4232
1 9102
1 5387
1 424
1 5677
1 750
1 3791
1 5008
1 2097
1 1138
1 6613
1 4471
1 9241
1 3898
1 3484
1 3710
1 3935
2 3448
2 2001
2 3747
2 6948
2 743
2 1131
2 2892
2 3951
2 5534
2 4241
2 1492
2 1007
2 4344
2 793
2 730
2 8446
2 7584
3 8642
3 2503
3 4361
3 ...

output:

114000.000000000

result:

ok found '114000.0000000', expected '114000.0000000', error '0.0000000'

Test #14:

score: 0
Accepted
time: 10ms
memory: 7664kb

input:

10000 92104 100
1 9378
1 1219
1 2085
1 8422
1 2406
1 5598
1 1323
1 8264
1 8942
1 4048
1 5426
1 5587
1 3675
1 3002
1 8251
1 9216
1 9086
1 2848
2 7655
2 2471
2 4717
2 750
2 9358
2 9812
2 8279
2 5876
2 8828
2 8861
2 7872
2 2336
3 3723
3 4519
3 6505
3 6314
3 9131
3 734
3 8505
3 3379
3 9259
3 8341
3 3606...

output:

138105.000000000

result:

ok found '138105.0000000', expected '138105.0000000', error '0.0000000'

Test #15:

score: 0
Accepted
time: 13ms
memory: 7748kb

input:

10000 92104 1000
1 6554
1 5218
1 7556
1 8229
1 8134
1 9671
1 5896
1 2857
1 2698
1 1336
1 3215
1 873
1 4741
1 3717
1 2168
1 3865
1 549
1 4135
1 2463
1 5664
2 9089
2 2050
2 5478
2 7752
2 4502
2 9546
2 6411
2 6284
2 1325
2 5006
2 2639
2 4953
2 2837
2 4815
2 5303
2 7498
2 281
2 4737
2 5279
2 7590
3 5699...

output:

592257.385281385

result:

ok found '592257.3852814', expected '592257.3852814', error '0.0000000'

Test #16:

score: 0
Accepted
time: 13ms
memory: 8016kb

input:

10000 92104 1000
1 7297
1 5388
1 2743
1 3273
1 8011
1 8460
1 5133
1 9744
1 336
1 7060
1 9046
1 9563
1 1308
1 6939
1 3807
1 2280
1 176
1 4916
1 9782
1 759
1 9592
1 3833
2 1250
2 4900
2 9687
2 8041
2 1901
2 4268
2 45
2 5968
2 3729
2 9289
2 7140
2 3189
2 6071
2 2810
2 953
2 1018
2 6427
2 3068
2 5758
2 ...

output:

606147.134920635

result:

ok found '606147.1349206', expected '606147.1349206', error '0.0000000'

Test #17:

score: 0
Accepted
time: 13ms
memory: 7824kb

input:

10000 92104 1000
1 135
1 2024
1 2761
1 5578
1 5707
1 4207
1 4606
1 3637
1 6487
1 3065
1 8346
1 5821
1 1694
1 4767
1 2560
2 7970
2 900
2 6693
2 7878
2 5223
2 5299
2 6669
2 2443
2 9421
2 1875
2 6255
2 3952
2 8817
2 5043
2 4122
2 837
2 5050
2 4960
2 9287
2 2591
2 2976
3 6405
3 7208
3 971
3 5448
3 2558
...

output:

564822.484126984

result:

ok found '564822.4841270', expected '564822.4841270', error '0.0000000'

Test #18:

score: 0
Accepted
time: 14ms
memory: 8796kb

input:

10000 92104 1000
1 7778
1 3420
1 1541
1 6823
1 6690
1 2921
1 1099
1 2732
1 4365
1 7347
1 7028
1 9390
1 8017
1 5395
1 6036
1 2008
1 229
1 9371
1 8604
1 9384
1 3128
2 8066
2 653
2 3460
2 9127
2 1290
2 3629
2 9295
2 6481
2 8211
2 7972
2 5141
2 311
2 9978
2 379
2 1436
2 4863
3 1441
3 2050
3 645
3 3208
3...

output:

620773.238095238

result:

ok found '620773.2380952', expected '620773.2380952', error '0.0000000'

Test #19:

score: 0
Accepted
time: 14ms
memory: 7740kb

input:

10000 92104 1000
1 5569
1 9410
1 1508
1 7238
1 5976
1 772
1 5915
1 8075
1 8750
1 5377
1 1890
2 7777
2 6946
2 7108
2 230
2 8777
2 3453
2 2541
2 8974
2 431
2 4432
2 3797
2 8655
2 3575
2 6906
2 3509
2 795
2 4070
2 4189
2 646
3 226
3 5444
3 3301
3 7846
3 5128
3 7657
3 9066
3 952
3 9325
3 2706
3 8403
3 4...

output:

539340.571428571

result:

ok found '539340.5714286', expected '539340.5714286', error '0.0000000'

Test #20:

score: 0
Accepted
time: 20ms
memory: 10628kb

input:

100000 99999 1000
1 2
1 3
1 5
1 82575
1 76
1 6339
1 15
1 17
1 19
1 59359
1 3192
1 1209
1 37
1 7839
2 12
2 101
2 9
2 47754
2 364
2 2446
2 3950
2 530
2 20341
2 1046
2 383
3 66
3 467
3 4
3 15510
3 1538
3 41
3 3258
3 61
3 54623
4 2818
4 36631
4 8
4 74
4 13
4 20
4 17142
4 6999
4 90
4 156
4 31
5 2793
5 35...

output:

109430.000000000

result:

ok found '109430.0000000', expected '109430.0000000', error '0.0000000'

Test #21:

score: 0
Accepted
time: 21ms
memory: 10716kb

input:

100000 99999 1000
1 2
1 3
1 23
1 10
1 31416
1 19
1 62512
1 6033
1 10195
1 5719
1 4056
1 57
1 1309
1 11646
2 66
2 5
2 582
2 15447
2 578
2 299
2 15068
2 1357
2 12923
2 39232
3 4
3 37
3 972
3 14
3 111
3 24336
3 5617
3 82821
3 24
3 26
3 411
3 44028
3 315
3 56
4 9121
4 6
4 7
4 8
4 16745
4 12
4 1815
4 767...

output:

119024.000000000

result:

ok found '119024.0000000', expected '119024.0000000', error '0.0000000'

Test #22:

score: 0
Accepted
time: 19ms
memory: 10636kb

input:

100000 99999 1000
1 2
1 3
1 60508
1 1237
1 776
1 139
1 6812
1 6835
2 674
2 5
2 40
2 1193
2 10
2 4748
2 16
2 401
2 114
2 245
2 14041
2 8389
2 287
3 259
3 4
3 75152
3 11332
3 9
3 539
3 28
3 143
3 7968
4 20102
4 84820
4 22
4 23
4 8
4 2395
4 21552
4 60142
4 1808
5 148
5 6
5 7
5 15010
5 543
5 44
5 84923
...

output:

100186.000000000

result:

ok found '100186.0000000', expected '100186.0000000', error '0.0000000'

Test #23:

score: 0
Accepted
time: 29ms
memory: 10792kb

input:

100000 99999 50000
1 54593
1 2
1 8743
1 7
1 98
1 9
1 29
1 8
1 3566
1 720
1 882
1 2266
1 444
1 605
1 768
2 3
2 580
2 390
2 92
2 1069
2 25524
2 3887
2 1430
3 1379
3 4
3 1605
3 4354
3 1577
3 16139
3 45
3 37619
3 17
3 18
3 19
3 24
3 250
3 5627
3 13086
4 3569
4 165
4 5
4 6
5 20
5 1701
5 4806
5 1528
5 135...

output:

1585160.896825389

result:

ok found '1585160.8968254', expected '1585160.8968254', error '0.0000000'

Test #24:

score: 0
Accepted
time: 23ms
memory: 10656kb

input:

100000 99999 50000
1 2
1 3
1 52549
1 38
1 34
1 74
1 1291
1 36527
1 30
1 49
1 154
1 555
2 56273
2 4
2 1829
2 70
2 87
2 298
2 26795
2 108
2 15574
3 55491
3 196
3 6
3 34282
3 8463
3 51697
3 691
3 16604
3 27836
3 31
3 12230
4 2433
4 1860
4 5
4 1959
4 7
4 234
4 29191
4 76
4 14
4 2383
4 19025
4 18
4 44
4 ...

output:

1543835.611111102

result:

ok found '1543835.6111111', expected '1543835.6111111', error '0.0000000'

Test #25:

score: 0
Accepted
time: 21ms
memory: 10708kb

input:

100000 99999 50000
1 2
1 103
1 10919
1 425
1 43
1 16
1 4401
1 27634
1 627
1 11477
1 12503
1 24
2 578
2 3
2 5
2 38
2 41
2 10
2 44
2 13
2 93107
2 114
2 691
2 133
2 379
3 83075
3 4
3 6
3 49159
3 11
3 11213
3 1360
3 116
3 215
3 7
3 20763
4 21106
4 39834
4 46619
4 3772
4 333
4 595
4 32078
5 50065
5 661
5...

output:

1583353.309523802

result:

ok found '1583353.3095238', expected '1583353.3095238', error '0.0000000'

Test #26:

score: 0
Accepted
time: 24ms
memory: 10656kb

input:

100000 99999 90000
1 2
1 59298
1 246
1 167
1 1560
1 5655
1 28
1 3054
1 80
2 65
2 3
2 6
2 7
2 1714
2 553
2 9166
2 978
2 62945
2 2626
2 64
3 4
3 3142
3 329
3 714
3 139
3 39212
3 109
3 937
3 468
3 117
3 9
3 86714
4 354
4 5
4 38
4 71
4 8
4 393
4 10
4 77
4 1058
4 17
4 87
4 26040
4 88429
4 1723
4 960
4 58...

output:

345783.731990231

result:

ok found '345783.7319902', expected '345783.7319902', error '0.0000000'

Test #27:

score: 0
Accepted
time: 21ms
memory: 10792kb

input:

100000 99999 90000
1 2
1 12
1 581
1 678
1 7
1 40
1 552
1 71776
1 8
1 82351
1 10576
1 77650
1 595
1 52
1 1684
1 48408
1 160
1 95
1 456
2 67009
2 3
2 4
2 1608
2 10
2 6136
2 23907
2 77489
2 1252
2 58
2 219
2 122
2 1243
2 123
2 319
3 243
3 612
3 5
3 6
3 870
3 27282
3 20613
3 8812
3 4286
3 262
4 71153
4 ...

output:

346418.971972472

result:

ok found '346418.9719725', expected '346418.9719725', error '0.0000000'

Test #28:

score: 0
Accepted
time: 25ms
memory: 10764kb

input:

100000 99999 90000
1 33
1 2
1 7148
1 5
1 7810
1 396
1 751
1 688
1 49
1 19
1 181
1 22
1 2853
1 27
1 3631
1 61
2 50
2 3
2 53
2 24
2 51977
2 170
2 82682
3 1601
3 46579
3 4
3 7
3 263
3 1561
3 43353
3 35447
3 32239
3 81020
4 5570
4 3574
4 71
4 152
4 622
4 47
4 61424
5 12132
5 6
5 8
5 9
5 2186
5 11560
5 7...

output:

361059.938672438

result:

ok found '361059.9386724', expected '361059.9386724', error '0.0000000'

Test #29:

score: 0
Accepted
time: 16ms
memory: 8044kb

input:

20000 100000 1000
1 2
1 3
1 6
1 8681
1 8269
1 1225
1 16662
1 19997
1 19998
1 20000
2 9762
2 3
2 5
2 6
2 7
2 3554
2 16330
2 4113
2 3191
2 19998
3 4
3 5
3 6
3 7
3 6151
3 13371
3 19999
4 5
4 6
4 7
4 8
4 9
4 3863
4 19999
5 6
5 8
5 9
5 18664
5 1137
5 1473
5 4433
5 1943
5 19432
5 20000
6 7
6 8
6 9
6 11
6 ...

output:

647699.000000000

result:

ok found '647699.0000000', expected '647699.0000000', error '0.0000000'