QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#491679 | #4205. Art Collections | kimmoqt# | 70 | 1382ms | 4104kb | C++20 | 1.2kb | 2024-07-25 20:58:23 | 2024-07-25 20:58:23 |
Judging History
answer
#include "art.h"
//
// --- Sample implementation for the task art ---
//
// To compile this program with the sample grader, place:
// art.h art_sample.cpp sample_grader.cpp
// in a single folder, then open the terminal in this directory (right-click onto an empty spot in the directory,
// left click on "Open in terminal") and enter e.g.:
// g++ -std=c++17 art_sample.cpp sample_grader.cpp
// in this folder. This will create a file a.out in the current directory which you can execute from the terminal
// as ./a.out
// See task statement or sample_grader.cpp for the input specification
//
#include <bits/stdc++.h>
using namespace std;
void solve(int N) {
vector<int> P(N);
for(int i=1;i<=N;i++) {
vector<int> A;
for(int j=1;j<=N;j++)
if(j!=i) A.push_back(j);
A.push_back(i);
vector<int> B;
B.push_back(i);
for(int j=1;j<=N;j++)
if(j!=i) B.push_back(j);
int x=publish(A), y=publish(B);
int p=y-x;
int q=N-1;
int z=(p+q)/2;
P[z]=i;
}
answer(P);
}
詳細信息
Subtask #1:
score: 5
Accepted
Test #1:
score: 5
Accepted
time: 1ms
memory: 3868kb
input:
6 10 15 11 14 12 13 13 12 14 11 15 10
output:
942318468 6 2 3 4 5 6 1 942318468 6 1 2 3 4 5 6 942318468 6 1 3 4 5 6 2 942318468 6 2 1 3 4 5 6 942318468 6 1 2 4 5 6 3 942318468 6 3 1 2 4 5 6 942318468 6 1 2 3 5 6 4 942318468 6 4 1 2 3 5 6 942318468 6 1 2 3 4 6 5 942318468 6 5 1 2 3 4 6 942318468 6 1 2 3 4 5 6 942318468 6 6 1 2 3 4 5 539883183 6 ...
result:
ok correct
Test #2:
score: 5
Accepted
time: 1ms
memory: 3792kb
input:
6 4 9 7 8 10 7 11 6 10 9 9 12
output:
942318468 6 2 3 4 5 6 1 942318468 6 1 2 3 4 5 6 942318468 6 1 3 4 5 6 2 942318468 6 2 1 3 4 5 6 942318468 6 1 2 4 5 6 3 942318468 6 3 1 2 4 5 6 942318468 6 1 2 3 5 6 4 942318468 6 4 1 2 3 5 6 942318468 6 1 2 3 4 6 5 942318468 6 5 1 2 3 4 6 942318468 6 1 2 3 4 5 6 942318468 6 6 1 2 3 4 5 539883183 6 ...
result:
ok correct
Test #3:
score: 5
Accepted
time: 1ms
memory: 4084kb
input:
6 4 9 7 8 10 7 11 6 10 9 9 12
output:
942318468 6 2 3 4 5 6 1 942318468 6 1 2 3 4 5 6 942318468 6 1 3 4 5 6 2 942318468 6 2 1 3 4 5 6 942318468 6 1 2 4 5 6 3 942318468 6 3 1 2 4 5 6 942318468 6 1 2 3 5 6 4 942318468 6 4 1 2 3 5 6 942318468 6 1 2 3 4 6 5 942318468 6 5 1 2 3 4 6 942318468 6 1 2 3 4 5 6 942318468 6 6 1 2 3 4 5 539883183 6 ...
result:
ok correct
Test #4:
score: 5
Accepted
time: 1ms
memory: 4088kb
input:
6 4 9 7 8 10 7 11 6 10 9 9 12
output:
942318468 6 2 3 4 5 6 1 942318468 6 1 2 3 4 5 6 942318468 6 1 3 4 5 6 2 942318468 6 2 1 3 4 5 6 942318468 6 1 2 4 5 6 3 942318468 6 3 1 2 4 5 6 942318468 6 1 2 3 5 6 4 942318468 6 4 1 2 3 5 6 942318468 6 1 2 3 4 6 5 942318468 6 5 1 2 3 4 6 942318468 6 1 2 3 4 5 6 942318468 6 6 1 2 3 4 5 539883183 6 ...
result:
ok correct
Test #5:
score: 5
Accepted
time: 1ms
memory: 3776kb
input:
3 3 1 0 2 1 1
output:
942318468 3 2 3 1 942318468 3 1 2 3 942318468 3 1 3 2 942318468 3 2 1 3 942318468 3 1 2 3 942318468 3 3 1 2 539883183 3 1 3 2
result:
ok correct
Test #6:
score: 5
Accepted
time: 0ms
memory: 4024kb
input:
6 5 0 4 1 3 2 2 3 1 4 0 5
output:
942318468 6 2 3 4 5 6 1 942318468 6 1 2 3 4 5 6 942318468 6 1 3 4 5 6 2 942318468 6 2 1 3 4 5 6 942318468 6 1 2 4 5 6 3 942318468 6 3 1 2 4 5 6 942318468 6 1 2 3 5 6 4 942318468 6 4 1 2 3 5 6 942318468 6 1 2 3 4 6 5 942318468 6 5 1 2 3 4 6 942318468 6 1 2 3 4 5 6 942318468 6 6 1 2 3 4 5 539883183 6 ...
result:
ok correct
Test #7:
score: 5
Accepted
time: 1ms
memory: 3852kb
input:
6 4 9 7 8 10 7 11 6 10 9 9 12
output:
942318468 6 2 3 4 5 6 1 942318468 6 1 2 3 4 5 6 942318468 6 1 3 4 5 6 2 942318468 6 2 1 3 4 5 6 942318468 6 1 2 4 5 6 3 942318468 6 3 1 2 4 5 6 942318468 6 1 2 3 5 6 4 942318468 6 4 1 2 3 5 6 942318468 6 1 2 3 4 6 5 942318468 6 5 1 2 3 4 6 942318468 6 1 2 3 4 5 6 942318468 6 6 1 2 3 4 5 539883183 6 ...
result:
ok correct
Subtask #2:
score: 15
Accepted
Test #8:
score: 15
Accepted
time: 1ms
memory: 3796kb
input:
40 407 394 362 395 403 394 382 395 425 390 386 395 379 398 420 389 405 390 408 389 393 396 384 401 413 386 398 395 369 408 416 379 375 406 384 405 399 392 374 411 399 388 398 393 401 380 406 377 379 414 396 397 395 400 386 411 389 404 386 413 389 400 392 391 393 376 396 371 395 372 394 401 395 362 3...
output:
942318468 40 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 1 942318468 40 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 942318468 40 1 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17...
result:
ok correct
Test #9:
score: 15
Accepted
time: 1ms
memory: 3772kb
input:
40 407 394 362 395 403 394 382 395 425 390 386 395 379 398 420 389 405 390 408 389 393 396 384 401 413 386 398 395 369 408 416 379 375 406 384 405 399 392 374 411 399 388 398 393 401 380 406 377 379 414 396 397 395 400 386 411 389 404 386 413 389 400 392 391 393 376 396 371 395 372 394 401 395 362 3...
output:
942318468 40 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 1 942318468 40 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 942318468 40 1 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17...
result:
ok correct
Test #10:
score: 15
Accepted
time: 1ms
memory: 3796kb
input:
40 407 394 362 395 403 394 382 395 425 390 386 395 379 398 420 389 405 390 408 389 393 396 384 401 413 386 398 395 369 408 416 379 375 406 384 405 399 392 374 411 399 388 398 393 401 380 406 377 379 414 396 397 395 400 386 411 389 404 386 413 389 400 392 391 393 376 396 371 395 372 394 401 395 362 3...
output:
942318468 40 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 1 942318468 40 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 942318468 40 1 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17...
result:
ok correct
Test #11:
score: 15
Accepted
time: 1ms
memory: 3800kb
input:
40 407 394 362 395 403 394 382 395 425 390 386 395 379 398 420 389 405 390 408 389 393 396 384 401 413 386 398 395 369 408 416 379 375 406 384 405 399 392 374 411 399 388 398 393 401 380 406 377 379 414 396 397 395 400 386 411 389 404 386 413 389 400 392 391 393 376 396 371 395 372 394 401 395 362 3...
output:
942318468 40 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 1 942318468 40 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 942318468 40 1 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17...
result:
ok correct
Test #12:
score: 15
Accepted
time: 1ms
memory: 3776kb
input:
40 741 780 742 779 743 778 744 777 745 776 746 775 747 774 748 773 749 772 750 771 751 770 752 769 753 768 754 767 755 766 756 765 757 764 758 763 759 762 760 761 761 760 762 759 763 758 764 757 765 756 766 755 767 754 768 753 769 752 770 751 771 750 772 749 773 748 774 747 775 746 776 745 777 744 7...
output:
942318468 40 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 1 942318468 40 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 942318468 40 1 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17...
result:
ok correct
Test #13:
score: 15
Accepted
time: 1ms
memory: 4056kb
input:
40 39 0 38 1 37 2 36 3 35 4 34 5 33 6 32 7 31 8 30 9 29 10 28 11 27 12 26 13 25 14 24 15 23 16 22 17 21 18 20 19 19 20 18 21 17 22 16 23 15 24 14 25 13 26 12 27 11 28 10 29 9 30 8 31 7 32 6 33 5 34 4 35 3 36 2 37 1 38 0 39
output:
942318468 40 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 1 942318468 40 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 942318468 40 1 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17...
result:
ok correct
Subtask #3:
score: 15
Accepted
Test #14:
score: 15
Accepted
time: 9ms
memory: 3800kb
input:
250 30876 31125 30877 31124 30878 31123 30879 31122 30880 31121 30881 31120 30882 31119 30883 31118 30884 31117 30885 31116 30886 31115 30887 31114 30888 31113 30889 31112 30890 31111 30891 31110 30892 31109 30893 31108 30894 31107 30895 31106 30896 31105 30897 31104 30898 31103 30899 31102 30900 31...
output:
942318468 250 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #15:
score: 15
Accepted
time: 8ms
memory: 3796kb
input:
250 15490 15389 15535 15388 15406 15391 15473 15390 15332 15393 15297 15394 15396 15391 15385 15392 15438 15387 15455 15386 15586 15379 15573 15380 15614 15377 15297 15402 15552 15381 15621 15374 15240 15405 15537 15382 15396 15397 15263 15406 15292 15405 15377 15398 15502 15381 15607 15368 15304 15...
output:
942318468 250 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #16:
score: 15
Accepted
time: 7ms
memory: 3772kb
input:
250 249 0 248 1 247 2 246 3 245 4 244 5 243 6 242 7 241 8 240 9 239 10 238 11 237 12 236 13 235 14 234 15 233 16 232 17 231 18 230 19 229 20 228 21 227 22 226 23 225 24 224 25 223 26 222 27 221 28 220 29 219 30 218 31 217 32 216 33 215 34 214 35 213 36 212 37 211 38 210 39 209 40 208 41 207 42 206 4...
output:
942318468 250 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #17:
score: 15
Accepted
time: 9ms
memory: 3772kb
input:
250 15490 15389 15535 15388 15406 15391 15473 15390 15332 15393 15297 15394 15396 15391 15385 15392 15438 15387 15455 15386 15586 15379 15573 15380 15614 15377 15297 15402 15552 15381 15621 15374 15240 15405 15537 15382 15396 15397 15263 15406 15292 15405 15377 15398 15502 15381 15607 15368 15304 15...
output:
942318468 250 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #18:
score: 15
Accepted
time: 8ms
memory: 3772kb
input:
250 15490 15389 15535 15388 15406 15391 15473 15390 15332 15393 15297 15394 15396 15391 15385 15392 15438 15387 15455 15386 15586 15379 15573 15380 15614 15377 15297 15402 15552 15381 15621 15374 15240 15405 15537 15382 15396 15397 15263 15406 15292 15405 15377 15398 15502 15381 15607 15368 15304 15...
output:
942318468 250 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #19:
score: 15
Accepted
time: 0ms
memory: 3864kb
input:
250 15490 15389 15535 15388 15406 15391 15473 15390 15332 15393 15297 15394 15396 15391 15385 15392 15438 15387 15455 15386 15586 15379 15573 15380 15614 15377 15297 15402 15552 15381 15621 15374 15240 15405 15537 15382 15396 15397 15263 15406 15292 15405 15377 15398 15502 15381 15607 15368 15304 15...
output:
942318468 250 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Subtask #4:
score: 15
Accepted
Test #20:
score: 15
Accepted
time: 16ms
memory: 3784kb
input:
444 47894 48125 48465 48124 47944 48125 47949 48124 48256 48123 48221 48124 48320 48121 47865 48132 48364 48119 48381 48118 48516 48115 48503 48116 48544 48113 47853 48138 47818 48139 48551 48110 48158 48129 47793 48142 48316 48123 48179 48128 47852 48141 48295 48122 48428 48113 48537 48104 48222 48...
output:
942318468 444 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #21:
score: 15
Accepted
time: 23ms
memory: 4060kb
input:
444 443 0 442 1 441 2 440 3 439 4 438 5 437 6 436 7 435 8 434 9 433 10 432 11 431 12 430 13 429 14 428 15 427 16 426 17 425 18 424 19 423 20 422 21 421 22 420 23 419 24 418 25 417 26 416 27 415 28 414 29 413 30 412 31 411 32 410 33 409 34 408 35 407 36 406 37 405 38 404 39 403 40 402 41 401 42 400 4...
output:
942318468 444 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #22:
score: 15
Accepted
time: 19ms
memory: 4064kb
input:
444 47894 48125 48465 48124 47944 48125 47949 48124 48256 48123 48221 48124 48320 48121 47865 48132 48364 48119 48381 48118 48516 48115 48503 48116 48544 48113 47853 48138 47818 48139 48551 48110 48158 48129 47793 48142 48316 48123 48179 48128 47852 48141 48295 48122 48428 48113 48537 48104 48222 48...
output:
942318468 444 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #23:
score: 15
Accepted
time: 18ms
memory: 3776kb
input:
444 47894 48125 48465 48124 47944 48125 47949 48124 48256 48123 48221 48124 48320 48121 47865 48132 48364 48119 48381 48118 48516 48115 48503 48116 48544 48113 47853 48138 47818 48139 48551 48110 48158 48129 47793 48142 48316 48123 48179 48128 47852 48141 48295 48122 48428 48113 48537 48104 48222 48...
output:
942318468 444 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #24:
score: 15
Accepted
time: 23ms
memory: 3872kb
input:
444 97903 98346 97904 98345 97905 98344 97906 98343 97907 98342 97908 98341 97909 98340 97910 98339 97911 98338 97912 98337 97913 98336 97914 98335 97915 98334 97916 98333 97917 98332 97918 98331 97919 98330 97920 98329 97921 98328 97922 98327 97923 98326 97924 98325 97925 98324 97926 98323 97927 98...
output:
942318468 444 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Test #25:
score: 15
Accepted
time: 24ms
memory: 3780kb
input:
444 47894 48125 48465 48124 47944 48125 47949 48124 48256 48123 48221 48124 48320 48121 47865 48132 48364 48119 48381 48118 48516 48115 48503 48116 48544 48113 47853 48138 47818 48139 48551 48110 48158 48129 47793 48142 48316 48123 48179 48128 47852 48141 48295 48122 48428 48113 48537 48104 48222 48...
output:
942318468 444 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 ...
result:
ok correct
Subtask #5:
score: 20
Accepted
Test #26:
score: 20
Accepted
time: 567ms
memory: 3892kb
input:
2000 983364 984031 984747 984030 984400 984031 983481 984032 984772 984027 984027 984032 983690 984033 985313 984024 984998 984025 982075 984040 985978 984021 983213 984040 984120 984031 982847 984042 985256 984021 986013 984016 983892 984035 984063 984032 985074 984021 983689 984040 984388 984029 9...
output:
942318468 2000 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99...
result:
ok correct
Test #27:
score: 20
Accepted
time: 592ms
memory: 4104kb
input:
2000 983364 984031 984747 984030 984400 984031 983481 984032 984772 984027 984027 984032 983690 984033 985313 984024 984998 984025 982075 984040 985978 984021 983213 984040 984120 984031 982847 984042 985256 984021 986013 984016 983892 984035 984063 984032 985074 984021 983689 984040 984388 984029 9...
output:
942318468 2000 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99...
result:
ok correct
Test #28:
score: 20
Accepted
time: 550ms
memory: 3764kb
input:
2000 1999 0 1998 1 1997 2 1996 3 1995 4 1994 5 1993 6 1992 7 1991 8 1990 9 1989 10 1988 11 1987 12 1986 13 1985 14 1984 15 1983 16 1982 17 1981 18 1980 19 1979 20 1978 21 1977 22 1976 23 1975 24 1974 25 1973 26 1972 27 1971 28 1970 29 1969 30 1968 31 1967 32 1966 33 1965 34 1964 35 1963 36 1962 37 1...
output:
942318468 2000 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99...
result:
ok correct
Test #29:
score: 20
Accepted
time: 565ms
memory: 3812kb
input:
2000 1997001 1999000 1997002 1998999 1997003 1998998 1997004 1998997 1997005 1998996 1997006 1998995 1997007 1998994 1997008 1998993 1997009 1998992 1997010 1998991 1997011 1998990 1997012 1998989 1997013 1998988 1997014 1998987 1997015 1998986 1997016 1998985 1997017 1998984 1997018 1998983 1997019...
output:
942318468 2000 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99...
result:
ok correct
Test #30:
score: 20
Accepted
time: 569ms
memory: 3764kb
input:
2000 983364 984031 984747 984030 984400 984031 983481 984032 984772 984027 984027 984032 983690 984033 985313 984024 984998 984025 982075 984040 985978 984021 983213 984040 984120 984031 982847 984042 985256 984021 986013 984016 983892 984035 984063 984032 985074 984021 983689 984040 984388 984029 9...
output:
942318468 2000 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99...
result:
ok correct
Test #31:
score: 20
Accepted
time: 573ms
memory: 3800kb
input:
2000 983364 984031 984747 984030 984400 984031 983481 984032 984772 984027 984027 984032 983690 984033 985313 984024 984998 984025 982075 984040 985978 984021 983213 984040 984120 984031 982847 984042 985256 984021 986013 984016 983892 984035 984063 984032 985074 984021 983689 984040 984388 984029 9...
output:
942318468 2000 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99...
result:
ok correct
Subtask #6:
score: 0
Wrong Answer
Test #32:
score: 0
Wrong Answer
time: 1382ms
memory: 3880kb
input:
4000 3955888 3954555 3950653 3954556 3952838 3954555 3956001 3954552 3957296 3954551 3950627 3954560 3951632 3954557 3954197 3954554 3957520 3954547 3954589 3954554 3951072 3954561 3955725 3954552 3951160 3954561 3955357 3954552 3952108 3954559 3958537 3954540 3956402 3954545 3956575 3954544 3957592...
output:
942318468 4000 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99...
result:
wrong answer Too many queries