QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#478640#2012. 树的重心Milmon0 663ms33212kbC++142.2kb2024-07-15 08:45:482024-07-15 08:45:48

详细

Test #1:

score: 0
Wrong Answer
time: 0ms
memory: 13824kb

input:

5
7
1 6
2 4
5 3
3 7
6 4
4 7
7
1 5
2 7
3 6
4 7
6 5
5 7
7
3 2
2 7
4 7
5 1
1 7
6 7
7
1 4
2 7
3 4
4 6
6 5
5 7
7
2 1
3 6
5 7
6 1
1 4
4 7

output:

77
83
71
84
62

result:

wrong answer 1st numbers differ - expected: '73', found: '77'

Test #2:

score: 0
Wrong Answer
time: 2ms
memory: 14088kb

input:

5
7
2 1
3 1
1 5
4 5
5 6
6 7
7
1 6
2 3
4 5
6 5
5 3
3 7
7
4 7
5 3
6 2
2 1
1 3
3 7
7
4 2
2 1
1 5
5 3
3 7
6 7
7
5 2
6 1
1 2
2 3
3 4
4 7

output:

64
69
61
79
62

result:

wrong answer 2nd numbers differ - expected: '64', found: '69'

Test #3:

score: 0
Wrong Answer
time: 2ms
memory: 14008kb

input:

5
199
7 46
10 170
17 190
23 22
22 67
31 13
13 116
34 100
36 91
37 195
39 88
40 139
43 187
47 158
48 83
49 128
50 30
54 26
26 169
59 85
60 178
65 191
73 28
28 41
75 56
76 82
77 133
80 55
55 44
81 150
87 92
89 74
90 110
91 123
92 163
93 42
42 44
44 180
95 35
35 66
66 161
96 176
97 3
98 140
101 38
103 ...

output:

59317
64214
60571
40367
58504

result:

wrong answer 1st numbers differ - expected: '54835', found: '59317'

Test #4:

score: 0
Wrong Answer
time: 3ms
memory: 13796kb

input:

5
199
1 169
4 29
5 117
8 30
14 17
15 71
16 180
18 103
20 193
24 38
29 100
32 12
12 39
33 23
23 108
35 40
36 139
37 40
46 95
49 112
50 106
51 108
52 58
53 151
56 176
57 22
60 184
68 39
70 58
58 67
67 25
71 47
74 170
75 114
76 31
31 34
80 90
81 62
82 83
83 100
85 77
92 146
94 146
98 96
96 156
99 195
1...

output:

57997
63906
35361
58687
52591

result:

wrong answer 1st numbers differ - expected: '49937', found: '57997'

Test #5:

score: 0
Wrong Answer
time: 0ms
memory: 15664kb

input:

5
199
6 193
7 82
9 39
12 29
13 180
14 101
17 172
19 108
35 66
36 156
42 129
49 55
52 40
54 28
28 112
58 136
61 53
53 74
63 179
65 33
33 110
68 4
71 127
75 4
4 167
76 197
77 150
79 31
31 197
82 18
18 165
86 187
87 178
88 143
90 196
92 66
66 166
94 5
5 78
78 140
95 130
97 154
99 169
101 185
103 74
74 ...

output:

66170
60725
55973
54935
51630

result:

wrong answer 1st numbers differ - expected: '60385', found: '66170'

Test #6:

score: 0
Wrong Answer
time: 4ms
memory: 14284kb

input:

5
1999
3 1248
6 1223
9 1663
12 360
14 1607
15 530
16 847
21 1010
25 733
28 947
32 1077
34 821
35 674
39 1017
40 967
45 430
50 529
51 1012
52 148
53 719
54 293
55 609
57 1047
58 582
60 142
66 1280
67 1530
68 717
69 70
70 746
71 1874
75 218
76 205
77 1498
80 1185
90 1026
94 711
95 385
98 1165
99 277
1...

output:

4418265
5194536
4902686
3652307
6002365

result:

wrong answer 1st numbers differ - expected: '4415301', found: '4418265'

Test #7:

score: 0
Wrong Answer
time: 0ms
memory: 15716kb

input:

5
1999
1 243
2 1365
7 1088
11 1076
12 1102
15 9
18 516
20 1854
22 82
23 1532
25 809
28 973
31 1873
32 113
39 280
43 1138
44 1225
46 1289
47 948
48 814
52 863
54 1950
55 175
61 178
63 1081
66 282
68 1618
70 1306
71 314
74 771
80 406
81 565
82 777
83 1701
86 1247
87 1505
88 1816
90 77
94 308
96 1269
9...

output:

5218183
3976476
3133680
3563559
6115750

result:

wrong answer 1st numbers differ - expected: '5138639', found: '5218183'

Test #8:

score: 0
Wrong Answer
time: 0ms
memory: 14832kb

input:

5
1999
4 1262
6 1067
10 316
13 1983
14 610
15 945
18 192
22 532
24 688
29 385
30 1545
31 1061
37 1970
38 335
39 487
40 475
44 72
45 1468
47 470
49 873
50 1173
51 88
55 1366
56 1107
57 751
59 1340
60 636
63 1172
65 387
66 1286
69 681
70 489
75 1354
76 1958
77 910
78 1423
80 1696
81 328
83 1001
84 147...

output:

4427155
3796776
3244865
5471756
6851872

result:

wrong answer 1st numbers differ - expected: '4417145', found: '4427155'

Test #9:

score: 0
Wrong Answer
time: 100ms
memory: 20084kb

input:

5
49991
19763 10669
10669 20671
20671 35073
35073 22011
22011 39334
39334 16893
16893 36734
36734 35671
35671 24827
24827 5929
5929 22587
22587 16048
16048 24772
24772 40459
40459 37541
37541 33520
33520 47457
47457 23144
23144 40864
40864 13214
13214 23056
23056 19449
19449 41897
41897 23570
23570 ...

output:

4256151845
3952274054
4036718552
4732109573
3993792970

result:

wrong answer 1st numbers differ - expected: '3748673669', found: '4256151845'

Test #10:

score: 0
Wrong Answer
time: 104ms
memory: 20656kb

input:

5
49991
17601 40966
40966 35434
35434 29765
29765 29569
29569 11520
11520 8262
8262 21778
21778 21137
21137 21481
21481 5034
5034 29974
29974 12934
12934 47299
47299 14541
14541 5632
5632 8467
8467 39604
39604 38825
38825 24334
24334 5304
5304 47890
47890 17264
17264 819
819 31896
31896 49966
49966 ...

output:

4198848025
4075369601
4709501955
4211045194
4552262314

result:

wrong answer 1st numbers differ - expected: '3748681091', found: '4198848025'

Test #11:

score: 0
Wrong Answer
time: 100ms
memory: 20580kb

input:

5
49991
17601 40966
40966 35434
35434 29765
29765 29569
29569 11520
11520 8262
8262 21778
21778 21137
21137 21481
21481 5034
5034 29974
29974 12934
12934 47299
47299 14541
14541 5632
5632 8467
8467 39604
39604 38825
38825 24334
24334 5304
5304 47890
47890 17264
17264 819
819 31896
31896 49966
49966 ...

output:

4198848025
4075369601
4709501955
4211045194
4552262314

result:

wrong answer 1st numbers differ - expected: '3748681091', found: '4198848025'

Test #12:

score: 0
Wrong Answer
time: 515ms
memory: 23952kb

input:

5
262143
146770 175612
146770 60732
175612 53530
175612 157976
60732 129972
60732 8262
53530 208343
53530 241810
157976 54045
157976 125169
129972 77022
129972 12934
8262 139684
8262 132308
208343 202200
208343 113975
241810 96796
241810 231714
54045 214868
54045 206276
125169 254469
125169 177432
7...

output:

94193314340
124581101481
76811187102
79045160687
80799529536

result:

wrong answer 1st numbers differ - expected: '84574742390', found: '94193314340'

Test #13:

score: 0
Wrong Answer
time: 535ms
memory: 23808kb

input:

5
262143
79000 96360
79000 91210
96360 171486
96360 192733
91210 113737
91210 175804
171486 165391
171486 148872
192733 50082
192733 84694
113737 124373
113737 151080
175804 28512
175804 195077
165391 185052
165391 170088
148872 3444
148872 159445
50082 261317
50082 44496
84694 224968
84694 158634
1...

output:

74476468766
82667490909
68546334117
85670687890
75220198573

result:

wrong answer 1st numbers differ - expected: '69299203766', found: '74476468766'

Test #14:

score: 0
Wrong Answer
time: 523ms
memory: 23836kb

input:

5
262143
80668 139094
80668 22182
139094 143143
139094 134409
22182 60477
22182 162265
143143 227503
143143 1560
134409 85115
134409 185254
60477 128516
60477 35671
162265 138714
162265 205852
227503 211287
227503 118458
1560 122509
1560 173622
85115 161651
85115 200495
185254 33882
185254 63113
128...

output:

71358026700
120907890121
95881011411
90025396400
91964706460

result:

wrong answer 1st numbers differ - expected: '66071449320', found: '71358026700'

Test #15:

score: 0
Wrong Answer
time: 513ms
memory: 23920kb

input:

5
262143
134055 112409
134055 173361
112409 142281
112409 158535
173361 29319
173361 78805
142281 38595
142281 58788
158535 138588
158535 255716
29319 35295
29319 233057
78805 136424
78805 137397
38595 21026
38595 233348
58788 150537
58788 159016
138588 250059
138588 154684
255716 102400
255716 1721...

output:

98171784296
119987384003
89079236588
88216388190
114118169276

result:

wrong answer 1st numbers differ - expected: '89386489871', found: '98171784296'

Test #16:

score: 0
Wrong Answer
time: 194ms
memory: 20464kb

input:

5
99995
259 33949
24431 46214
70531 47343
30948 7638
78110 39021
66676 61827
68226 23740
447 9624
73693 93832
51936 60316
70665 71118
34707 39970
79419 24476
46318 73713
13318 81365
203 61537
15901 1647
15871 94799
2179 98495
44986 18479
742 59873
21425 22057
53003 83148
1938 71642
96209 12362
85249...

output:

12326191407
11933081648
13766309144
9561148642
16927829653

result:

wrong answer 1st numbers differ - expected: '12305515311', found: '12326191407'

Test #17:

score: 0
Wrong Answer
time: 414ms
memory: 25980kb

input:

5
199995
138306 178143
126692 90580
195249 41160
183019 129512
30948 65522
174231 160304
62697 53062
34707 136319
119438 13105
86673 47289
21484 63852
135033 177492
88820 41556
127597 11667
38660 9688
20532 47907
199457 156229
19863 119502
124210 148366
53003 31552
130020 22624
138539 78394
125197 1...

output:

49098584362
58204762828
30771078369
33632211722
36453004239

result:

wrong answer 1st numbers differ - expected: '47819479252', found: '49098584362'

Test #18:

score: 0
Wrong Answer
time: 417ms
memory: 27256kb

input:

5
199995
175791 121334
164012 66489
62892 65680
158225 14074
191070 165961
53626 106523
110768 25732
168560 2805
33591 198570
25518 182266
193051 47804
171184 195743
175898 49560
105280 165577
137932 33634
75375 129044
109365 164280
125769 147064
170883 197513
162323 100475
47461 181353
80970 151789...

output:

26726621147
31116861064
49229636814
56437623753
49416515650

result:

wrong answer 1st numbers differ - expected: '26717669079', found: '26726621147'

Test #19:

score: 0
Wrong Answer
time: 655ms
memory: 31424kb

input:

5
299995
150147 169846
139337 63773
185064 212052
77320 23419
156180 162102
63142 20120
225131 146038
212549 20016
46406 42169
286305 140266
13104 5614
270163 227814
148262 9967
27434 252557
217908 105623
138578 103358
36469 211475
18717 236263
13867 41398
91671 91198
263412 104644
167079 204277
187...

output:

74717324252
101609569637
123625710605
131863080300
100285148657

result:

wrong answer 1st numbers differ - expected: '74615066593', found: '74717324252'

Test #20:

score: 0
Wrong Answer
time: 663ms
memory: 33212kb

input:

5
299995
284734 56982
179603 60848
62377 129299
263286 294600
275034 103994
101598 17127
4082 162607
101427 121742
51111 114853
74024 22822
107874 97512
145157 37145
76679 153213
103753 6327
1108 29718
51455 213273
40667 290500
12308 112958
39082 104741
25356 54011
282325 107031
79497 19021
194864 2...

output:

67614362161
85270786693
108267767309
114819760710
138199318839

result:

wrong answer 1st numbers differ - expected: '67086038686', found: '67614362161'