Task: | Pukkitappelu battle royale |
Sender: | aalto2024e_003 |
Submission time: | 2024-09-30 17:39:27 +0300 |
Language: | C++ (C++17) |
Status: | READY |
Result: | WRONG ANSWER |
test | verdict | time | |
---|---|---|---|
#1 | ACCEPTED | 0.00 s | details |
#2 | WRONG ANSWER | 0.00 s | details |
#3 | WRONG ANSWER | 0.00 s | details |
#4 | WRONG ANSWER | 0.00 s | details |
#5 | ACCEPTED | 0.00 s | details |
#6 | WRONG ANSWER | 0.00 s | details |
#7 | ACCEPTED | 0.00 s | details |
#8 | ACCEPTED | 0.00 s | details |
#9 | ACCEPTED | 0.00 s | details |
#10 | WRONG ANSWER | 0.00 s | details |
#11 | WRONG ANSWER | 0.00 s | details |
#12 | WRONG ANSWER | 0.00 s | details |
#13 | WRONG ANSWER | 0.00 s | details |
#14 | WRONG ANSWER | 0.00 s | details |
#15 | WRONG ANSWER | 0.00 s | details |
#16 | WRONG ANSWER | 0.00 s | details |
#17 | WRONG ANSWER | 0.00 s | details |
#18 | WRONG ANSWER | 0.00 s | details |
#19 | WRONG ANSWER | 0.00 s | details |
#20 | WRONG ANSWER | 0.00 s | details |
#21 | WRONG ANSWER | 0.00 s | details |
#22 | WRONG ANSWER | 0.00 s | details |
#23 | WRONG ANSWER | 0.00 s | details |
#24 | WRONG ANSWER | 0.00 s | details |
#25 | WRONG ANSWER | 0.00 s | details |
#26 | WRONG ANSWER | 0.00 s | details |
#27 | WRONG ANSWER | 0.00 s | details |
#28 | WRONG ANSWER | 0.00 s | details |
#29 | ACCEPTED | 0.00 s | details |
#30 | WRONG ANSWER | 0.00 s | details |
#31 | WRONG ANSWER | 0.00 s | details |
#32 | WRONG ANSWER | 0.00 s | details |
#33 | WRONG ANSWER | 0.00 s | details |
#34 | WRONG ANSWER | 0.00 s | details |
#35 | WRONG ANSWER | 0.00 s | details |
#36 | ACCEPTED | 0.00 s | details |
#37 | WRONG ANSWER | 0.00 s | details |
#38 | ACCEPTED | 0.00 s | details |
#39 | WRONG ANSWER | 0.00 s | details |
#40 | WRONG ANSWER | 0.00 s | details |
#41 | WRONG ANSWER | 0.00 s | details |
#42 | WRONG ANSWER | 0.00 s | details |
#43 | WRONG ANSWER | 0.00 s | details |
#44 | WRONG ANSWER | 0.00 s | details |
#45 | WRONG ANSWER | 0.00 s | details |
#46 | ACCEPTED | 0.00 s | details |
#47 | WRONG ANSWER | 0.00 s | details |
#48 | WRONG ANSWER | 0.00 s | details |
#49 | WRONG ANSWER | 0.00 s | details |
#50 | WRONG ANSWER | 0.00 s | details |
#51 | WRONG ANSWER | 0.00 s | details |
#52 | WRONG ANSWER | 0.00 s | details |
#53 | WRONG ANSWER | 0.00 s | details |
#54 | WRONG ANSWER | 0.00 s | details |
#55 | WRONG ANSWER | 0.00 s | details |
#56 | WRONG ANSWER | 0.00 s | details |
#57 | WRONG ANSWER | 0.00 s | details |
#58 | WRONG ANSWER | 0.00 s | details |
#59 | WRONG ANSWER | 0.00 s | details |
#60 | WRONG ANSWER | 0.00 s | details |
#61 | WRONG ANSWER | 0.00 s | details |
#62 | WRONG ANSWER | 0.00 s | details |
#63 | WRONG ANSWER | 0.00 s | details |
#64 | WRONG ANSWER | 0.00 s | details |
#65 | WRONG ANSWER | 0.00 s | details |
#66 | WRONG ANSWER | 0.00 s | details |
#67 | WRONG ANSWER | 0.00 s | details |
#68 | WRONG ANSWER | 0.00 s | details |
#69 | WRONG ANSWER | 0.00 s | details |
#70 | WRONG ANSWER | 0.01 s | details |
#71 | WRONG ANSWER | 0.00 s | details |
#72 | WRONG ANSWER | 0.00 s | details |
#73 | WRONG ANSWER | 0.00 s | details |
#74 | WRONG ANSWER | 0.00 s | details |
#75 | WRONG ANSWER | 0.00 s | details |
#76 | WRONG ANSWER | 0.00 s | details |
#77 | WRONG ANSWER | 0.00 s | details |
#78 | WRONG ANSWER | 0.00 s | details |
#79 | WRONG ANSWER | 0.00 s | details |
#80 | WRONG ANSWER | 0.02 s | details |
#81 | WRONG ANSWER | 0.02 s | details |
#82 | WRONG ANSWER | 0.02 s | details |
#83 | WRONG ANSWER | 0.02 s | details |
#84 | WRONG ANSWER | 0.02 s | details |
#85 | WRONG ANSWER | 0.02 s | details |
#86 | WRONG ANSWER | 0.02 s | details |
#87 | WRONG ANSWER | 0.02 s | details |
#88 | WRONG ANSWER | 0.02 s | details |
#89 | WRONG ANSWER | 0.01 s | details |
Code
#include <bits/stdc++.h> using namespace std; typedef long long ll; int main() { ios::sync_with_stdio(false); cin.tie(nullptr); ll n, x; cin >> n >> x; vector<ll> a(n); for (ll& pos : a) cin >> pos; ll total_moves = 0; total_moves += a[0] - 1; for (ll i = 0; i < n - 1; ++i) { total_moves += a[i + 1] - a[i] - 1; } total_moves += x - a[n - 1]; ll winner_index = (total_moves % n) + 1; cout << winner_index << '\n'; return 0; }
Test details
Test 1
Verdict: ACCEPTED
input |
---|
1 14 10 |
correct output |
---|
1 |
user output |
---|
1 |
Test 2
Verdict: WRONG ANSWER
input |
---|
2 10 1 2 |
correct output |
---|
2 |
user output |
---|
1 |
Test 3
Verdict: WRONG ANSWER
input |
---|
2 7 3 5 |
correct output |
---|
1 |
user output |
---|
2 |
Test 4
Verdict: WRONG ANSWER
input |
---|
2 13 4 12 |
correct output |
---|
1 |
user output |
---|
2 |
Test 5
Verdict: ACCEPTED
input |
---|
2 12 6 10 |
correct output |
---|
1 |
user output |
---|
1 |
Test 6
Verdict: WRONG ANSWER
input |
---|
2 6 3 6 |
correct output |
---|
2 |
user output |
---|
1 |
Test 7
Verdict: ACCEPTED
input |
---|
2 19 6 15 |
correct output |
---|
2 |
user output |
---|
2 |
Test 8
Verdict: ACCEPTED
input |
---|
2 16 2 14 |
correct output |
---|
1 |
user output |
---|
1 |
Test 9
Verdict: ACCEPTED
input |
---|
2 20 11 13 |
correct output |
---|
1 |
user output |
---|
1 |
Test 10
Verdict: WRONG ANSWER
input |
---|
2 17 7 15 |
correct output |
---|
1 |
user output |
---|
2 |
Test 11
Verdict: WRONG ANSWER
input |
---|
2 18 7 18 |
correct output |
---|
2 |
user output |
---|
1 |
Test 12
Verdict: WRONG ANSWER
input |
---|
3 8 1 6 8 |
correct output |
---|
2 |
user output |
---|
3 |
Test 13
Verdict: WRONG ANSWER
input |
---|
3 20 11 13 15 |
correct output |
---|
1 |
user output |
---|
3 |
Test 14
Verdict: WRONG ANSWER
input |
---|
3 8 3 6 8 |
correct output |
---|
2 |
user output |
---|
3 |
Test 15
Verdict: WRONG ANSWER
input |
---|
3 14 5 8 10 |
correct output |
---|
2 |
user output |
---|
3 |
Test 16
Verdict: WRONG ANSWER
input |
---|
3 3 1 2 3 |
correct output |
---|
3 |
user output |
---|
1 |
Test 17
Verdict: WRONG ANSWER
input |
---|
3 7 1 6 7 |
correct output |
---|
3 |
user output |
---|
2 |
Test 18
Verdict: WRONG ANSWER
input |
---|
3 12 3 10 11 |
correct output |
---|
3 |
user output |
---|
1 |
Test 19
Verdict: WRONG ANSWER
input |
---|
3 3 1 2 3 |
correct output |
---|
3 |
user output |
---|
1 |
Test 20
Verdict: WRONG ANSWER
input |
---|
3 3 1 2 3 |
correct output |
---|
3 |
user output |
---|
1 |
Test 21
Verdict: WRONG ANSWER
input |
---|
3 15 1 4 5 |
correct output |
---|
3 |
user output |
---|
1 |
Test 22
Verdict: WRONG ANSWER
input |
---|
3 10 6 8 9 |
correct output |
---|
3 |
user output |
---|
2 |
Test 23
Verdict: WRONG ANSWER
input |
---|
3 13 8 9 12 |
correct output |
---|
3 |
user output |
---|
2 |
Test 24
Verdict: WRONG ANSWER
input |
---|
4 20 2 8 13 14 |
correct output |
---|
4 |
user output |
---|
1 |
Test 25
Verdict: WRONG ANSWER
input |
---|
4 20 12 13 14 18 |
correct output |
---|
3 |
user output |
---|
1 |
Test 26
Verdict: WRONG ANSWER
input |
---|
4 13 2 4 12 13 |
correct output |
---|
4 |
user output |
---|
2 |
Test 27
Verdict: WRONG ANSWER
input |
---|
4 13 1 3 7 13 |
correct output |
---|
1 |
user output |
---|
2 |
Test 28
Verdict: WRONG ANSWER
input |
---|
4 16 5 7 8 15 |
correct output |
---|
4 |
user output |
---|
1 |
Test 29
Verdict: ACCEPTED
input |
---|
4 11 7 8 10 11 |
correct output |
---|
4 |
user output |
---|
4 |
Test 30
Verdict: WRONG ANSWER
input |
---|
5 13 6 8 10 11 12 |
correct output |
---|
5 |
user output |
---|
4 |
Test 31
Verdict: WRONG ANSWER
input |
---|
5 11 1 2 4 8 11 |
correct output |
---|
5 |
user output |
---|
2 |
Test 32
Verdict: WRONG ANSWER
input |
---|
5 11 1 3 5 7 11 |
correct output |
---|
1 |
user output |
---|
2 |
Test 33
Verdict: WRONG ANSWER
input |
---|
5 13 1 2 4 10 11 |
correct output |
---|
5 |
user output |
---|
4 |
Test 34
Verdict: WRONG ANSWER
input |
---|
5 20 4 11 18 19 20 |
correct output |
---|
5 |
user output |
---|
1 |
Test 35
Verdict: WRONG ANSWER
input |
---|
5 8 1 2 3 7 8 |
correct output |
---|
5 |
user output |
---|
4 |
Test 36
Verdict: ACCEPTED
input |
---|
5 19 2 4 7 16 19 |
correct output |
---|
5 |
user output |
---|
5 |
Test 37
Verdict: WRONG ANSWER
input |
---|
5 6 2 3 4 5 6 |
correct output |
---|
5 |
user output |
---|
2 |
Test 38
Verdict: ACCEPTED
input |
---|
5 18 1 5 7 16 18 |
correct output |
---|
4 |
user output |
---|
4 |
Test 39
Verdict: WRONG ANSWER
input |
---|
5 5 1 2 3 4 5 |
correct output |
---|
5 |
user output |
---|
1 |
Test 40
Verdict: WRONG ANSWER
input |
---|
10 16 1 5 7 8 9 10 11 12 14 15 |
correct output |
---|
10 |
user output |
---|
7 |
Test 41
Verdict: WRONG ANSWER
input |
---|
10 14 1 2 3 4 5 6 8 10 11 14 |
correct output |
---|
10 |
user output |
---|
5 |
Test 42
Verdict: WRONG ANSWER
input |
---|
10 14 1 2 3 5 6 7 8 9 10 14 |
correct output |
---|
9 |
user output |
---|
5 |
Test 43
Verdict: WRONG ANSWER
input |
---|
10 16 1 2 3 5 7 9 10 12 14 15 |
correct output |
---|
10 |
user output |
---|
7 |
Test 44
Verdict: WRONG ANSWER
input |
---|
10 20 4 5 11 12 13 14 15 18 19 20 |
correct output |
---|
10 |
user output |
---|
1 |
Test 45
Verdict: WRONG ANSWER
input |
---|
10 12 1 2 3 5 6 7 8 10 11 12 |
correct output |
---|
10 |
user output |
---|
3 |
Test 46
Verdict: ACCEPTED
input |
---|
10 19 1 2 3 4 7 8 11 12 16 19 |
correct output |
---|
10 |
user output |
---|
10 |
Test 47
Verdict: WRONG ANSWER
input |
---|
10 10 1 2 3 4 5 6 7 8 9 10 |
correct output |
---|
10 |
user output |
---|
1 |
Test 48
Verdict: WRONG ANSWER
input |
---|
10 19 1 5 8 9 11 12 15 16 17 19 |
correct output |
---|
9 |
user output |
---|
10 |
Test 49
Verdict: WRONG ANSWER
input |
---|
10 10 1 2 3 4 5 6 7 8 9 10 |
correct output |
---|
10 |
user output |
---|
1 |
Test 50
Verdict: WRONG ANSWER
input |
---|
100 589284111 11528796 12405338 23576564 347... |
correct output |
---|
100 |
user output |
---|
12 |
Test 51
Verdict: WRONG ANSWER
input |
---|
100 447774061 54585 8727508 9242273 13069870... |
correct output |
---|
98 |
user output |
---|
62 |
Test 52
Verdict: WRONG ANSWER
input |
---|
100 468146062 12372478 31155934 38008300 391... |
correct output |
---|
99 |
user output |
---|
63 |
Test 53
Verdict: WRONG ANSWER
input |
---|
100 591414846 11503156 12648374 14184172 147... |
correct output |
---|
94 |
user output |
---|
47 |
Test 54
Verdict: WRONG ANSWER
input |
---|
100 967035023 5539596 6689688 9648746 204276... |
correct output |
---|
92 |
user output |
---|
24 |
Test 55
Verdict: WRONG ANSWER
input |
---|
100 238363452 391838 528333 1368439 3479103 ... |
correct output |
---|
95 |
user output |
---|
53 |
Test 56
Verdict: WRONG ANSWER
input |
---|
100 958701382 44771412 58491554 63972355 689... |
correct output |
---|
97 |
user output |
---|
83 |
Test 57
Verdict: WRONG ANSWER
input |
---|
100 81935503 1314125 2056565 5446047 595110... |
correct output |
---|
100 |
user output |
---|
4 |
Test 58
Verdict: WRONG ANSWER
input |
---|
100 937837780 11934038 12239373 22850648 308... |
correct output |
---|
100 |
user output |
---|
81 |
Test 59
Verdict: WRONG ANSWER
input |
---|
100 11139267 84150 148618 432268 440149 520... |
correct output |
---|
100 |
user output |
---|
68 |
Test 60
Verdict: WRONG ANSWER
input |
---|
200 589284211 2880992 5740962 8327109 115287... |
correct output |
---|
200 |
user output |
---|
12 |
Test 61
Verdict: WRONG ANSWER
input |
---|
200 447774161 54585 1369773 4298783 5568757 ... |
correct output |
---|
199 |
user output |
---|
162 |
Test 62
Verdict: WRONG ANSWER
input |
---|
200 468146162 2645901 6212116 12193387 12372... |
correct output |
---|
200 |
user output |
---|
163 |
Test 63
Verdict: WRONG ANSWER
input |
---|
200 591414946 11503156 12648374 13023409 141... |
correct output |
---|
197 |
user output |
---|
147 |
Test 64
Verdict: WRONG ANSWER
input |
---|
200 967035123 3142409 4210032 5539596 668968... |
correct output |
---|
200 |
user output |
---|
124 |
Test 65
Verdict: WRONG ANSWER
input |
---|
200 238363552 391838 528333 1368439 2951457 ... |
correct output |
---|
200 |
user output |
---|
153 |
Test 66
Verdict: WRONG ANSWER
input |
---|
200 958701482 915344 26318971 39308105 44426... |
correct output |
---|
200 |
user output |
---|
83 |
Test 67
Verdict: WRONG ANSWER
input |
---|
200 81935603 117854 1314125 2056565 3274591... |
correct output |
---|
200 |
user output |
---|
4 |
Test 68
Verdict: WRONG ANSWER
input |
---|
200 937837880 798751 8921056 9526547 1193403... |
correct output |
---|
200 |
user output |
---|
81 |
Test 69
Verdict: WRONG ANSWER
input |
---|
200 11139367 50914 81279 84150 90865 148618... |
correct output |
---|
200 |
user output |
---|
168 |
Test 70
Verdict: WRONG ANSWER
input |
---|
1000 589285011 33962 2483784 2880992 4837424 ... |
correct output |
---|
998 |
user output |
---|
12 |
Test 71
Verdict: WRONG ANSWER
input |
---|
1000 447774961 54585 191853 483557 1369773 14... |
correct output |
---|
1000 |
user output |
---|
962 |
Test 72
Verdict: WRONG ANSWER
input |
---|
1000 468146962 58977 735268 898440 1184659 12... |
correct output |
---|
1000 |
user output |
---|
963 |
Test 73
Verdict: WRONG ANSWER
input |
---|
1000 591415746 293786 457427 1304174 2617747 ... |
correct output |
---|
995 |
user output |
---|
747 |
Test 74
Verdict: WRONG ANSWER
input |
---|
1000 967035923 838480 973536 1455856 3142409 ... |
correct output |
---|
1000 |
user output |
---|
924 |
Test 75
Verdict: WRONG ANSWER
input |
---|
1000 238364352 91364 391838 528333 959636 117... |
correct output |
---|
998 |
user output |
---|
353 |
Test 76
Verdict: WRONG ANSWER
input |
---|
1000 958702282 557448 915344 2438616 2817236 ... |
correct output |
---|
1000 |
user output |
---|
283 |
Test 77
Verdict: WRONG ANSWER
input |
---|
1000 81936403 117854 134799 153186 216760 34... |
correct output |
---|
999 |
user output |
---|
404 |
Test 78
Verdict: WRONG ANSWER
input |
---|
1000 937838680 798751 996213 1265361 2336515 ... |
correct output |
---|
1000 |
user output |
---|
681 |
Test 79
Verdict: WRONG ANSWER
input |
---|
1000 11140167 3811 29493 33378 46013 50914 5... |
correct output |
---|
1000 |
user output |
---|
168 |
Test 80
Verdict: WRONG ANSWER
input |
---|
100000 589384011 2462 12290 14854 19988 28400 3... |
correct output |
---|
99996 |
user output |
---|
84012 |
Test 81
Verdict: WRONG ANSWER
input |
---|
100000 447873961 324 4948 5149 18319 22491 2468... |
correct output |
---|
100000 |
user output |
---|
73962 |
Test 82
Verdict: WRONG ANSWER
input |
---|
100000 468245962 9543 11563 11899 20558 24392 2... |
correct output |
---|
100000 |
user output |
---|
45963 |
Test 83
Verdict: WRONG ANSWER
input |
---|
100000 591514746 7688 9041 14326 23056 27308 28... |
correct output |
---|
99998 |
user output |
---|
14747 |
Test 84
Verdict: WRONG ANSWER
input |
---|
100000 967134923 1024 2994 6645 24256 27426 329... |
correct output |
---|
99997 |
user output |
---|
34924 |
Test 85
Verdict: WRONG ANSWER
input |
---|
100000 238463352 675 900 4012 15115 15476 22069... |
correct output |
---|
100000 |
user output |
---|
63353 |
Test 86
Verdict: WRONG ANSWER
input |
---|
100000 958801282 7177 18494 20083 35163 36876 4... |
correct output |
---|
99999 |
user output |
---|
1283 |
Test 87
Verdict: WRONG ANSWER
input |
---|
100000 82035403 237 539 626 1804 2747 3269 358... |
correct output |
---|
100000 |
user output |
---|
35404 |
Test 88
Verdict: WRONG ANSWER
input |
---|
100000 937937680 1191 7701 13173 20679 24337 30... |
correct output |
---|
100000 |
user output |
---|
37681 |
Test 89
Verdict: WRONG ANSWER
input |
---|
100000 11239167 70 124 318 547 595 692 784 880... |
correct output |
---|
99999 |
user output |
---|
39168 |