QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#287272#4205. Art Collections1437vszombies100 ✓905ms3256kbC++14437b2023-12-20 09:35:152023-12-20 09:35:16

Judging History

你现在查看的是最新测评结果

  • [2023-12-20 09:35:16]
  • 评测
  • 测评结果:100
  • 用时:905ms
  • 内存:3256kb
  • [2023-12-20 09:35:15]
  • 提交

answer

#include"art.h"
#include<vector>
#include<algorithm>
using namespace std;
void solve(int N) {
    vector<int> ans(N),num(N+5),tmp(N);
    for(int i=1;i<=N;++i){
    	for(int j=0;j<=N-i;++j)tmp[j]=j+i;
    	for(int j=N-i+1;j<N;++j)tmp[j]=j-(N-i);
    	reverse(tmp.begin(),tmp.end());
    	num[i]=publish(tmp);
	}
	num[N+1]=num[1];
	for(int i=1;i<=N;++i){
		int x=(num[i+1]-num[i]+1+N)/2;
		ans[x-1]=i;
	}
	answer(ans);
}

详细

Subtask #1:

score: 5
Accepted

Test #1:

score: 5
Accepted
time: 1ms
memory: 3048kb

input:

6
0
5
8
9
8
5

output:

942318468 6 6 5 4 3 2 1
942318468 6 1 6 5 4 3 2
942318468 6 2 1 6 5 4 3
942318468 6 3 2 1 6 5 4
942318468 6 4 3 2 1 6 5
942318468 6 5 4 3 2 1 6
539883183 6 6 5 4 3 2 1

result:

ok correct

Test #2:

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

input:

6
6
11
12
9
4
3

output:

942318468 6 6 5 4 3 2 1
942318468 6 1 6 5 4 3 2
942318468 6 2 1 6 5 4 3
942318468 6 3 2 1 6 5 4
942318468 6 4 3 2 1 6 5
942318468 6 5 4 3 2 1 6
539883183 6 4 3 5 2 6 1

result:

ok correct

Test #3:

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

input:

6
6
11
12
9
4
3

output:

942318468 6 6 5 4 3 2 1
942318468 6 1 6 5 4 3 2
942318468 6 2 1 6 5 4 3
942318468 6 3 2 1 6 5 4
942318468 6 4 3 2 1 6 5
942318468 6 5 4 3 2 1 6
539883183 6 4 3 5 2 6 1

result:

ok correct

Test #4:

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

input:

6
6
11
12
9
4
3

output:

942318468 6 6 5 4 3 2 1
942318468 6 1 6 5 4 3 2
942318468 6 2 1 6 5 4 3
942318468 6 3 2 1 6 5 4
942318468 6 4 3 2 1 6 5
942318468 6 5 4 3 2 1 6
539883183 6 4 3 5 2 6 1

result:

ok correct

Test #5:

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

input:

3
2
0
2

output:

942318468 3 3 2 1
942318468 3 1 3 2
942318468 3 2 1 3
539883183 3 1 3 2

result:

ok correct

Test #6:

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

input:

6
15
10
7
6
7
10

output:

942318468 6 6 5 4 3 2 1
942318468 6 1 6 5 4 3 2
942318468 6 2 1 6 5 4 3
942318468 6 3 2 1 6 5 4
942318468 6 4 3 2 1 6 5
942318468 6 5 4 3 2 1 6
539883183 6 1 2 3 4 5 6

result:

ok correct

Test #7:

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

input:

6
6
11
12
9
4
3

output:

942318468 6 6 5 4 3 2 1
942318468 6 1 6 5 4 3 2
942318468 6 2 1 6 5 4 3
942318468 6 3 2 1 6 5 4
942318468 6 4 3 2 1 6 5
942318468 6 5 4 3 2 1 6
539883183 6 4 3 5 2 6 1

result:

ok correct

Subtask #2:

score: 15
Accepted

Test #8:

score: 15
Accepted
time: 1ms
memory: 3052kb

input:

40
386
373
406
397
410
375
384
403
372
357
338
341
358
331
328
367
330
361
382
375
412
401
396
375
346
381
382
387
412
427
454
465
464
447
422
399
406
373
402
363

output:

942318468 40 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1
942318468 40 1 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2
942318468 40 2 1 40 39 38 37 36 35 34 33 32 31 30 29...

result:

ok correct

Test #9:

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

input:

40
386
373
406
397
410
375
384
403
372
357
338
341
358
331
328
367
330
361
382
375
412
401
396
375
346
381
382
387
412
427
454
465
464
447
422
399
406
373
402
363

output:

942318468 40 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1
942318468 40 1 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2
942318468 40 2 1 40 39 38 37 36 35 34 33 32 31 30 29...

result:

ok correct

Test #10:

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

input:

40
386
373
406
397
410
375
384
403
372
357
338
341
358
331
328
367
330
361
382
375
412
401
396
375
346
381
382
387
412
427
454
465
464
447
422
399
406
373
402
363

output:

942318468 40 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1
942318468 40 1 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2
942318468 40 2 1 40 39 38 37 36 35 34 33 32 31 30 29...

result:

ok correct

Test #11:

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

input:

40
386
373
406
397
410
375
384
403
372
357
338
341
358
331
328
367
330
361
382
375
412
401
396
375
346
381
382
387
412
427
454
465
464
447
422
399
406
373
402
363

output:

942318468 40 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1
942318468 40 1 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2
942318468 40 2 1 40 39 38 37 36 35 34 33 32 31 30 29...

result:

ok correct

Test #12:

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

input:

40
0
39
76
111
144
175
204
231
256
279
300
319
336
351
364
375
384
391
396
399
400
399
396
391
384
375
364
351
336
319
300
279
256
231
204
175
144
111
76
39

output:

942318468 40 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1
942318468 40 1 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2
942318468 40 2 1 40 39 38 37 36 35 34 33 32 31 30 29...

result:

ok correct

Test #13:

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

input:

40
780
741
704
669
636
605
576
549
524
501
480
461
444
429
416
405
396
389
384
381
380
381
384
389
396
405
416
429
444
461
480
501
524
549
576
605
636
669
704
741

output:

942318468 40 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1
942318468 40 1 40 39 38 37 36 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2
942318468 40 2 1 40 39 38 37 36 35 34 33 32 31 30 29...

result:

ok correct

Subtask #3:

score: 15
Accepted

Test #14:

score: 15
Accepted
time: 0ms
memory: 3048kb

input:

250
0
249
496
741
984
1225
1464
1701
1936
2169
2400
2629
2856
3081
3304
3525
3744
3961
4176
4389
4600
4809
5016
5221
5424
5625
5824
6021
6216
6409
6600
6789
6976
7161
7344
7525
7704
7881
8056
8229
8400
8569
8736
8901
9064
9225
9384
9541
9696
9849
10000
10149
10296
10441
10584
10725
10864
11001
11136...

output:

942318468 250 250 249 248 247 246 245 244 243 242 241 240 239 238 237 236 235 234 233 232 231 230 229 228 227 226 225 224 223 222 221 220 219 218 217 216 215 214 213 212 211 210 209 208 207 206 205 204 203 202 201 200 199 198 197 196 195 194 193 192 191 190 189 188 187 186 185 184 183 182 181 180 17...

result:

ok correct

Test #15:

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

input:

250
15736
15635
15488
15473
15390
15451
15548
15543
15550
15499
15430
15223
15030
14793
14898
14727
14480
14645
14490
14491
14634
14747
14768
14647
14408
14509
14300
14491
14352
14211
14198
14447
14510
14667
14612
14639
14710
14467
14536
14763
14744
14557
14770
14881
14650
14771
14592
14633
14638
14...

output:

942318468 250 250 249 248 247 246 245 244 243 242 241 240 239 238 237 236 235 234 233 232 231 230 229 228 227 226 225 224 223 222 221 220 219 218 217 216 215 214 213 212 211 210 209 208 207 206 205 204 203 202 201 200 199 198 197 196 195 194 193 192 191 190 189 188 187 186 185 184 183 182 181 180 17...

result:

ok correct

Test #16:

score: 0
Accepted
time: 4ms
memory: 3044kb

input:

250
31125
30876
30629
30384
30141
29900
29661
29424
29189
28956
28725
28496
28269
28044
27821
27600
27381
27164
26949
26736
26525
26316
26109
25904
25701
25500
25301
25104
24909
24716
24525
24336
24149
23964
23781
23600
23421
23244
23069
22896
22725
22556
22389
22224
22061
21900
21741
21584
21429
21...

output:

942318468 250 250 249 248 247 246 245 244 243 242 241 240 239 238 237 236 235 234 233 232 231 230 229 228 227 226 225 224 223 222 221 220 219 218 217 216 215 214 213 212 211 210 209 208 207 206 205 204 203 202 201 200 199 198 197 196 195 194 193 192 191 190 189 188 187 186 185 184 183 182 181 180 17...

result:

ok correct

Test #17:

score: 0
Accepted
time: 4ms
memory: 3228kb

input:

250
15736
15635
15488
15473
15390
15451
15548
15543
15550
15499
15430
15223
15030
14793
14898
14727
14480
14645
14490
14491
14634
14747
14768
14647
14408
14509
14300
14491
14352
14211
14198
14447
14510
14667
14612
14639
14710
14467
14536
14763
14744
14557
14770
14881
14650
14771
14592
14633
14638
14...

output:

942318468 250 250 249 248 247 246 245 244 243 242 241 240 239 238 237 236 235 234 233 232 231 230 229 228 227 226 225 224 223 222 221 220 219 218 217 216 215 214 213 212 211 210 209 208 207 206 205 204 203 202 201 200 199 198 197 196 195 194 193 192 191 190 189 188 187 186 185 184 183 182 181 180 17...

result:

ok correct

Test #18:

score: 0
Accepted
time: 4ms
memory: 3040kb

input:

250
15736
15635
15488
15473
15390
15451
15548
15543
15550
15499
15430
15223
15030
14793
14898
14727
14480
14645
14490
14491
14634
14747
14768
14647
14408
14509
14300
14491
14352
14211
14198
14447
14510
14667
14612
14639
14710
14467
14536
14763
14744
14557
14770
14881
14650
14771
14592
14633
14638
14...

output:

942318468 250 250 249 248 247 246 245 244 243 242 241 240 239 238 237 236 235 234 233 232 231 230 229 228 227 226 225 224 223 222 221 220 219 218 217 216 215 214 213 212 211 210 209 208 207 206 205 204 203 202 201 200 199 198 197 196 195 194 193 192 191 190 189 188 187 186 185 184 183 182 181 180 17...

result:

ok correct

Test #19:

score: 0
Accepted
time: 4ms
memory: 3052kb

input:

250
15736
15635
15488
15473
15390
15451
15548
15543
15550
15499
15430
15223
15030
14793
14898
14727
14480
14645
14490
14491
14634
14747
14768
14647
14408
14509
14300
14491
14352
14211
14198
14447
14510
14667
14612
14639
14710
14467
14536
14763
14744
14557
14770
14881
14650
14771
14592
14633
14638
14...

output:

942318468 250 250 249 248 247 246 245 244 243 242 241 240 239 238 237 236 235 234 233 232 231 230 229 228 227 226 225 224 223 222 221 220 219 218 217 216 215 214 213 212 211 210 209 208 207 206 205 204 203 202 201 200 199 198 197 196 195 194 193 192 191 190 189 188 187 186 185 184 183 182 181 180 17...

result:

ok correct

Subtask #4:

score: 15
Accepted

Test #20:

score: 15
Accepted
time: 11ms
memory: 3044kb

input:

444
50221
50452
50111
50292
50467
50334
50237
50038
50305
50060
49797
49396
49009
48578
48863
49184
48743
48714
49063
48870
48819
49108
48935
48620
48187
48094
47691
47688
48127
47792
48201
48284
48153
48302
48627
48460
48865
48428
48669
48702
49037
49200
49219
49656
49231
49158
48785
49082
48893
48...

output:

942318468 444 444 443 442 441 440 439 438 437 436 435 434 433 432 431 430 429 428 427 426 425 424 423 422 421 420 419 418 417 416 415 414 413 412 411 410 409 408 407 406 405 404 403 402 401 400 399 398 397 396 395 394 393 392 391 390 389 388 387 386 385 384 383 382 381 380 379 378 377 376 375 374 37...

result:

ok correct

Test #21:

score: 0
Accepted
time: 11ms
memory: 3108kb

input:

444
98346
97903
97462
97023
96586
96151
95718
95287
94858
94431
94006
93583
93162
92743
92326
91911
91498
91087
90678
90271
89866
89463
89062
88663
88266
87871
87478
87087
86698
86311
85926
85543
85162
84783
84406
84031
83658
83287
82918
82551
82186
81823
81462
81103
80746
80391
80038
79687
79338
78...

output:

942318468 444 444 443 442 441 440 439 438 437 436 435 434 433 432 431 430 429 428 427 426 425 424 423 422 421 420 419 418 417 416 415 414 413 412 411 410 409 408 407 406 405 404 403 402 401 400 399 398 397 396 395 394 393 392 391 390 389 388 387 386 385 384 383 382 381 380 379 378 377 376 375 374 37...

result:

ok correct

Test #22:

score: 0
Accepted
time: 8ms
memory: 3072kb

input:

444
50221
50452
50111
50292
50467
50334
50237
50038
50305
50060
49797
49396
49009
48578
48863
49184
48743
48714
49063
48870
48819
49108
48935
48620
48187
48094
47691
47688
48127
47792
48201
48284
48153
48302
48627
48460
48865
48428
48669
48702
49037
49200
49219
49656
49231
49158
48785
49082
48893
48...

output:

942318468 444 444 443 442 441 440 439 438 437 436 435 434 433 432 431 430 429 428 427 426 425 424 423 422 421 420 419 418 417 416 415 414 413 412 411 410 409 408 407 406 405 404 403 402 401 400 399 398 397 396 395 394 393 392 391 390 389 388 387 386 385 384 383 382 381 380 379 378 377 376 375 374 37...

result:

ok correct

Test #23:

score: 0
Accepted
time: 11ms
memory: 3100kb

input:

444
50221
50452
50111
50292
50467
50334
50237
50038
50305
50060
49797
49396
49009
48578
48863
49184
48743
48714
49063
48870
48819
49108
48935
48620
48187
48094
47691
47688
48127
47792
48201
48284
48153
48302
48627
48460
48865
48428
48669
48702
49037
49200
49219
49656
49231
49158
48785
49082
48893
48...

output:

942318468 444 444 443 442 441 440 439 438 437 436 435 434 433 432 431 430 429 428 427 426 425 424 423 422 421 420 419 418 417 416 415 414 413 412 411 410 409 408 407 406 405 404 403 402 401 400 399 398 397 396 395 394 393 392 391 390 389 388 387 386 385 384 383 382 381 380 379 378 377 376 375 374 37...

result:

ok correct

Test #24:

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

input:

444
0
443
884
1323
1760
2195
2628
3059
3488
3915
4340
4763
5184
5603
6020
6435
6848
7259
7668
8075
8480
8883
9284
9683
10080
10475
10868
11259
11648
12035
12420
12803
13184
13563
13940
14315
14688
15059
15428
15795
16160
16523
16884
17243
17600
17955
18308
18659
19008
19355
19700
20043
20384
20723
2...

output:

942318468 444 444 443 442 441 440 439 438 437 436 435 434 433 432 431 430 429 428 427 426 425 424 423 422 421 420 419 418 417 416 415 414 413 412 411 410 409 408 407 406 405 404 403 402 401 400 399 398 397 396 395 394 393 392 391 390 389 388 387 386 385 384 383 382 381 380 379 378 377 376 375 374 37...

result:

ok correct

Test #25:

score: 0
Accepted
time: 11ms
memory: 3056kb

input:

444
50221
50452
50111
50292
50467
50334
50237
50038
50305
50060
49797
49396
49009
48578
48863
49184
48743
48714
49063
48870
48819
49108
48935
48620
48187
48094
47691
47688
48127
47792
48201
48284
48153
48302
48627
48460
48865
48428
48669
48702
49037
49200
49219
49656
49231
49158
48785
49082
48893
48...

output:

942318468 444 444 443 442 441 440 439 438 437 436 435 434 433 432 431 430 429 428 427 426 425 424 423 422 421 420 419 418 417 416 415 414 413 412 411 410 409 408 407 406 405 404 403 402 401 400 399 398 397 396 395 394 393 392 391 390 389 388 387 386 385 384 383 382 381 380 379 378 377 376 375 374 37...

result:

ok correct

Subtask #5:

score: 20
Accepted

Test #26:

score: 20
Accepted
time: 162ms
memory: 3076kb

input:

2000
1014969
1015636
1014919
1014550
1015101
1014356
1014361
1014704
1013415
1012442
1014407
1012450
1013277
1013188
1014383
1013148
1011151
1011294
1011263
1010210
1010561
1010202
1010613
1012130
1010141
1009942
1008925
1007366
1008833
1007722
1006629
1008256
1009001
1007594
1006723
1008090
1007375...

output:

942318468 2000 2000 1999 1998 1997 1996 1995 1994 1993 1992 1991 1990 1989 1988 1987 1986 1985 1984 1983 1982 1981 1980 1979 1978 1977 1976 1975 1974 1973 1972 1971 1970 1969 1968 1967 1966 1965 1964 1963 1962 1961 1960 1959 1958 1957 1956 1955 1954 1953 1952 1951 1950 1949 1948 1947 1946 1945 1944 ...

result:

ok correct

Test #27:

score: 0
Accepted
time: 204ms
memory: 3128kb

input:

2000
1014969
1015636
1014919
1014550
1015101
1014356
1014361
1014704
1013415
1012442
1014407
1012450
1013277
1013188
1014383
1013148
1011151
1011294
1011263
1010210
1010561
1010202
1010613
1012130
1010141
1009942
1008925
1007366
1008833
1007722
1006629
1008256
1009001
1007594
1006723
1008090
1007375...

output:

942318468 2000 2000 1999 1998 1997 1996 1995 1994 1993 1992 1991 1990 1989 1988 1987 1986 1985 1984 1983 1982 1981 1980 1979 1978 1977 1976 1975 1974 1973 1972 1971 1970 1969 1968 1967 1966 1965 1964 1963 1962 1961 1960 1959 1958 1957 1956 1955 1954 1953 1952 1951 1950 1949 1948 1947 1946 1945 1944 ...

result:

ok correct

Test #28:

score: 0
Accepted
time: 199ms
memory: 3072kb

input:

2000
1999000
1997001
1995004
1993009
1991016
1989025
1987036
1985049
1983064
1981081
1979100
1977121
1975144
1973169
1971196
1969225
1967256
1965289
1963324
1961361
1959400
1957441
1955484
1953529
1951576
1949625
1947676
1945729
1943784
1941841
1939900
1937961
1936024
1934089
1932156
1930225
1928296...

output:

942318468 2000 2000 1999 1998 1997 1996 1995 1994 1993 1992 1991 1990 1989 1988 1987 1986 1985 1984 1983 1982 1981 1980 1979 1978 1977 1976 1975 1974 1973 1972 1971 1970 1969 1968 1967 1966 1965 1964 1963 1962 1961 1960 1959 1958 1957 1956 1955 1954 1953 1952 1951 1950 1949 1948 1947 1946 1945 1944 ...

result:

ok correct

Test #29:

score: 0
Accepted
time: 192ms
memory: 3080kb

input:

2000
0
1999
3996
5991
7984
9975
11964
13951
15936
17919
19900
21879
23856
25831
27804
29775
31744
33711
35676
37639
39600
41559
43516
45471
47424
49375
51324
53271
55216
57159
59100
61039
62976
64911
66844
68775
70704
72631
74556
76479
78400
80319
82236
84151
86064
87975
89884
91791
93696
95599
9750...

output:

942318468 2000 2000 1999 1998 1997 1996 1995 1994 1993 1992 1991 1990 1989 1988 1987 1986 1985 1984 1983 1982 1981 1980 1979 1978 1977 1976 1975 1974 1973 1972 1971 1970 1969 1968 1967 1966 1965 1964 1963 1962 1961 1960 1959 1958 1957 1956 1955 1954 1953 1952 1951 1950 1949 1948 1947 1946 1945 1944 ...

result:

ok correct

Test #30:

score: 0
Accepted
time: 164ms
memory: 3256kb

input:

2000
1014969
1015636
1014919
1014550
1015101
1014356
1014361
1014704
1013415
1012442
1014407
1012450
1013277
1013188
1014383
1013148
1011151
1011294
1011263
1010210
1010561
1010202
1010613
1012130
1010141
1009942
1008925
1007366
1008833
1007722
1006629
1008256
1009001
1007594
1006723
1008090
1007375...

output:

942318468 2000 2000 1999 1998 1997 1996 1995 1994 1993 1992 1991 1990 1989 1988 1987 1986 1985 1984 1983 1982 1981 1980 1979 1978 1977 1976 1975 1974 1973 1972 1971 1970 1969 1968 1967 1966 1965 1964 1963 1962 1961 1960 1959 1958 1957 1956 1955 1954 1953 1952 1951 1950 1949 1948 1947 1946 1945 1944 ...

result:

ok correct

Test #31:

score: 0
Accepted
time: 186ms
memory: 3128kb

input:

2000
1014969
1015636
1014919
1014550
1015101
1014356
1014361
1014704
1013415
1012442
1014407
1012450
1013277
1013188
1014383
1013148
1011151
1011294
1011263
1010210
1010561
1010202
1010613
1012130
1010141
1009942
1008925
1007366
1008833
1007722
1006629
1008256
1009001
1007594
1006723
1008090
1007375...

output:

942318468 2000 2000 1999 1998 1997 1996 1995 1994 1993 1992 1991 1990 1989 1988 1987 1986 1985 1984 1983 1982 1981 1980 1979 1978 1977 1976 1975 1974 1973 1972 1971 1970 1969 1968 1967 1966 1965 1964 1963 1962 1961 1960 1959 1958 1957 1956 1955 1954 1953 1952 1951 1950 1949 1948 1947 1946 1945 1944 ...

result:

ok correct

Subtask #6:

score: 30
Accepted

Test #32:

score: 30
Accepted
time: 905ms
memory: 3232kb

input:

4000
4043445
4042112
4046015
4047732
4046283
4043538
4047471
4050396
4050753
4047780
4047745
4051234
4050061
4053462
4052657
4055108
4051111
4049254
4047223
4044170
4047567
4049014
4052471
4052600
4056425
4054226
4051209
4047650
4047117
4044006
4045949
4045576
4044321
4040914
4044643
4044010
4044117...

output:

942318468 4000 4000 3999 3998 3997 3996 3995 3994 3993 3992 3991 3990 3989 3988 3987 3986 3985 3984 3983 3982 3981 3980 3979 3978 3977 3976 3975 3974 3973 3972 3971 3970 3969 3968 3967 3966 3965 3964 3963 3962 3961 3960 3959 3958 3957 3956 3955 3954 3953 3952 3951 3950 3949 3948 3947 3946 3945 3944 ...

result:

ok correct

Test #33:

score: 0
Accepted
time: 781ms
memory: 3100kb

input:

4000
7998000
7994001
7990004
7986009
7982016
7978025
7974036
7970049
7966064
7962081
7958100
7954121
7950144
7946169
7942196
7938225
7934256
7930289
7926324
7922361
7918400
7914441
7910484
7906529
7902576
7898625
7894676
7890729
7886784
7882841
7878900
7874961
7871024
7867089
7863156
7859225
7855296...

output:

942318468 4000 4000 3999 3998 3997 3996 3995 3994 3993 3992 3991 3990 3989 3988 3987 3986 3985 3984 3983 3982 3981 3980 3979 3978 3977 3976 3975 3974 3973 3972 3971 3970 3969 3968 3967 3966 3965 3964 3963 3962 3961 3960 3959 3958 3957 3956 3955 3954 3953 3952 3951 3950 3949 3948 3947 3946 3945 3944 ...

result:

ok correct

Test #34:

score: 0
Accepted
time: 849ms
memory: 3172kb

input:

4000
4043445
4042112
4046015
4047732
4046283
4043538
4047471
4050396
4050753
4047780
4047745
4051234
4050061
4053462
4052657
4055108
4051111
4049254
4047223
4044170
4047567
4049014
4052471
4052600
4056425
4054226
4051209
4047650
4047117
4044006
4045949
4045576
4044321
4040914
4044643
4044010
4044117...

output:

942318468 4000 4000 3999 3998 3997 3996 3995 3994 3993 3992 3991 3990 3989 3988 3987 3986 3985 3984 3983 3982 3981 3980 3979 3978 3977 3976 3975 3974 3973 3972 3971 3970 3969 3968 3967 3966 3965 3964 3963 3962 3961 3960 3959 3958 3957 3956 3955 3954 3953 3952 3951 3950 3949 3948 3947 3946 3945 3944 ...

result:

ok correct

Test #35:

score: 0
Accepted
time: 838ms
memory: 3116kb

input:

4000
0
3999
7996
11991
15984
19975
23964
27951
31936
35919
39900
43879
47856
51831
55804
59775
63744
67711
71676
75639
79600
83559
87516
91471
95424
99375
103324
107271
111216
115159
119100
123039
126976
130911
134844
138775
142704
146631
150556
154479
158400
162319
166236
170151
174064
177975
18188...

output:

942318468 4000 4000 3999 3998 3997 3996 3995 3994 3993 3992 3991 3990 3989 3988 3987 3986 3985 3984 3983 3982 3981 3980 3979 3978 3977 3976 3975 3974 3973 3972 3971 3970 3969 3968 3967 3966 3965 3964 3963 3962 3961 3960 3959 3958 3957 3956 3955 3954 3953 3952 3951 3950 3949 3948 3947 3946 3945 3944 ...

result:

ok correct

Test #36:

score: 0
Accepted
time: 871ms
memory: 3092kb

input:

4000
4043445
4042112
4046015
4047732
4046283
4043538
4047471
4050396
4050753
4047780
4047745
4051234
4050061
4053462
4052657
4055108
4051111
4049254
4047223
4044170
4047567
4049014
4052471
4052600
4056425
4054226
4051209
4047650
4047117
4044006
4045949
4045576
4044321
4040914
4044643
4044010
4044117...

output:

942318468 4000 4000 3999 3998 3997 3996 3995 3994 3993 3992 3991 3990 3989 3988 3987 3986 3985 3984 3983 3982 3981 3980 3979 3978 3977 3976 3975 3974 3973 3972 3971 3970 3969 3968 3967 3966 3965 3964 3963 3962 3961 3960 3959 3958 3957 3956 3955 3954 3953 3952 3951 3950 3949 3948 3947 3946 3945 3944 ...

result:

ok correct

Test #37:

score: 0
Accepted
time: 863ms
memory: 3164kb

input:

4000
4043445
4042112
4046015
4047732
4046283
4043538
4047471
4050396
4050753
4047780
4047745
4051234
4050061
4053462
4052657
4055108
4051111
4049254
4047223
4044170
4047567
4049014
4052471
4052600
4056425
4054226
4051209
4047650
4047117
4044006
4045949
4045576
4044321
4040914
4044643
4044010
4044117...

output:

942318468 4000 4000 3999 3998 3997 3996 3995 3994 3993 3992 3991 3990 3989 3988 3987 3986 3985 3984 3983 3982 3981 3980 3979 3978 3977 3976 3975 3974 3973 3972 3971 3970 3969 3968 3967 3966 3965 3964 3963 3962 3961 3960 3959 3958 3957 3956 3955 3954 3953 3952 3951 3950 3949 3948 3947 3946 3945 3944 ...

result:

ok correct