# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
793426 |
2023-07-25T20:12:25 Z |
Johann |
Council (JOI23_council) |
C++14 |
|
959 ms |
58768 KB |
#include "bits/stdc++.h"
using namespace std;
typedef vector<int> vi;
typedef vector<vi> vvi;
typedef pair<int, int> pii;
typedef vector<pii> vpii;
typedef vector<vpii> vvpii;
pii operator+(const pii &a, const pii &b) { return {a.first + b.first, a.second + b.second}; }
#define sz(x) (int)(x).size()
#define all(x) (x).begin(), (x).end()
int N, M;
vvi A;
vi votes;
int vr; // votes required
vi trans, transR;
int dp[1 << 20][2];
void addRes(int i, int idx)
{
if (idx == dp[i][0] || idx == dp[i][1])
return;
for (int j = 0; j < 2 && idx != -1; ++j)
{
if (dp[i][j] == -1 || __builtin_popcount(trans[idx] & i) < __builtin_popcount(trans[dp[i][j]] & i))
swap(dp[i][j], idx);
}
}
int main()
{
ios::sync_with_stdio(false);
cin.tie(0);
cin >> N >> M;
vr = N / 2;
A.assign(N, vi(M));
votes.assign(M, 0);
trans.assign(N, 0);
transR.assign(N, 0);
for (int i = 0; i < N; ++i)
{
for (int j = 0; j < M; ++j)
{
cin >> A[i][j];
votes[j] += A[i][j];
trans[i] |= (A[i][j]) ? (1 << j) : 0;
}
}
for (int i = 0; i < 1 << M; ++i)
dp[i][0] = dp[i][1] = -1;
for (int i = 0; i < N; ++i)
addRes(((1 << M) - 1) & ~trans[i], i);
for (int i = (1 << M) - 1; i >= 0; --i)
{
for (int k = 0; k < M; ++k)
{
if (i & (1 << k))
for (int j = 0; j < 2; ++j)
addRes(i ^ (1 << k), dp[i][j]);
}
}
for (int i = 0; i < (1 << M); ++i)
{
for (int k = 0; k < M; ++k)
{
if (!(i & (1 << k)))
for (int j = 0; j < 2; ++j)
addRes(i ^ (1 << k), dp[i][j]);
}
}
for (int i = 0; i < N; ++i)
{
int ans = 0;
int pattern = 0;
for (int k = 0; k < M; ++k)
{
if (votes[k] - A[i][k] >= vr)
++ans;
if (votes[k] - A[i][k] == vr)
pattern |= 1 << k;
}
int j = dp[pattern][0];
if (j == i)
j = dp[pattern][1];
cout << ans - __builtin_popcount(pattern & trans[j]) << "\n";
}
return 0;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
340 KB |
Output is correct |
3 |
Correct |
0 ms |
212 KB |
Output is correct |
4 |
Correct |
0 ms |
212 KB |
Output is correct |
5 |
Correct |
180 ms |
8524 KB |
Output is correct |
6 |
Correct |
155 ms |
8552 KB |
Output is correct |
7 |
Correct |
198 ms |
8512 KB |
Output is correct |
8 |
Correct |
276 ms |
8532 KB |
Output is correct |
9 |
Correct |
355 ms |
8560 KB |
Output is correct |
10 |
Correct |
235 ms |
8520 KB |
Output is correct |
11 |
Correct |
304 ms |
8512 KB |
Output is correct |
12 |
Correct |
368 ms |
8528 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
328 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
328 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
0 ms |
212 KB |
Output is correct |
21 |
Correct |
0 ms |
340 KB |
Output is correct |
22 |
Correct |
1 ms |
324 KB |
Output is correct |
23 |
Correct |
0 ms |
212 KB |
Output is correct |
24 |
Correct |
0 ms |
212 KB |
Output is correct |
25 |
Correct |
0 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
340 KB |
Output is correct |
27 |
Correct |
0 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
332 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
212 KB |
Output is correct |
31 |
Correct |
1 ms |
340 KB |
Output is correct |
32 |
Correct |
1 ms |
212 KB |
Output is correct |
33 |
Correct |
1 ms |
328 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
1 ms |
212 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
1 ms |
324 KB |
Output is correct |
39 |
Correct |
1 ms |
340 KB |
Output is correct |
40 |
Correct |
1 ms |
340 KB |
Output is correct |
41 |
Correct |
3 ms |
340 KB |
Output is correct |
42 |
Correct |
3 ms |
340 KB |
Output is correct |
43 |
Correct |
4 ms |
460 KB |
Output is correct |
44 |
Correct |
4 ms |
340 KB |
Output is correct |
45 |
Correct |
4 ms |
452 KB |
Output is correct |
46 |
Correct |
21 ms |
1236 KB |
Output is correct |
47 |
Correct |
25 ms |
1236 KB |
Output is correct |
48 |
Correct |
32 ms |
1236 KB |
Output is correct |
49 |
Correct |
26 ms |
1236 KB |
Output is correct |
50 |
Correct |
31 ms |
1340 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
340 KB |
Output is correct |
3 |
Correct |
0 ms |
212 KB |
Output is correct |
4 |
Correct |
0 ms |
212 KB |
Output is correct |
5 |
Correct |
180 ms |
8524 KB |
Output is correct |
6 |
Correct |
155 ms |
8552 KB |
Output is correct |
7 |
Correct |
198 ms |
8512 KB |
Output is correct |
8 |
Correct |
276 ms |
8532 KB |
Output is correct |
9 |
Correct |
355 ms |
8560 KB |
Output is correct |
10 |
Correct |
235 ms |
8520 KB |
Output is correct |
11 |
Correct |
304 ms |
8512 KB |
Output is correct |
12 |
Correct |
368 ms |
8528 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
328 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
328 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
0 ms |
212 KB |
Output is correct |
21 |
Correct |
0 ms |
340 KB |
Output is correct |
22 |
Correct |
1 ms |
324 KB |
Output is correct |
23 |
Correct |
0 ms |
212 KB |
Output is correct |
24 |
Correct |
0 ms |
212 KB |
Output is correct |
25 |
Correct |
0 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
340 KB |
Output is correct |
27 |
Correct |
0 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
332 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
212 KB |
Output is correct |
31 |
Correct |
1 ms |
340 KB |
Output is correct |
32 |
Correct |
1 ms |
212 KB |
Output is correct |
33 |
Correct |
1 ms |
328 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
1 ms |
212 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
1 ms |
324 KB |
Output is correct |
39 |
Correct |
1 ms |
340 KB |
Output is correct |
40 |
Correct |
1 ms |
340 KB |
Output is correct |
41 |
Correct |
3 ms |
340 KB |
Output is correct |
42 |
Correct |
3 ms |
340 KB |
Output is correct |
43 |
Correct |
4 ms |
460 KB |
Output is correct |
44 |
Correct |
4 ms |
340 KB |
Output is correct |
45 |
Correct |
4 ms |
452 KB |
Output is correct |
46 |
Correct |
21 ms |
1236 KB |
Output is correct |
47 |
Correct |
25 ms |
1236 KB |
Output is correct |
48 |
Correct |
32 ms |
1236 KB |
Output is correct |
49 |
Correct |
26 ms |
1236 KB |
Output is correct |
50 |
Correct |
31 ms |
1340 KB |
Output is correct |
51 |
Correct |
160 ms |
9004 KB |
Output is correct |
52 |
Correct |
159 ms |
8916 KB |
Output is correct |
53 |
Correct |
307 ms |
9016 KB |
Output is correct |
54 |
Correct |
386 ms |
9008 KB |
Output is correct |
55 |
Correct |
1 ms |
468 KB |
Output is correct |
56 |
Correct |
53 ms |
1788 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
212 KB |
Output is correct |
2 |
Correct |
58 ms |
20768 KB |
Output is correct |
3 |
Correct |
64 ms |
20764 KB |
Output is correct |
4 |
Correct |
53 ms |
20248 KB |
Output is correct |
5 |
Correct |
61 ms |
20764 KB |
Output is correct |
6 |
Correct |
50 ms |
20256 KB |
Output is correct |
7 |
Correct |
65 ms |
20788 KB |
Output is correct |
8 |
Correct |
0 ms |
212 KB |
Output is correct |
9 |
Correct |
0 ms |
212 KB |
Output is correct |
10 |
Correct |
0 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
248 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
468 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
212 KB |
Output is correct |
2 |
Correct |
58 ms |
20768 KB |
Output is correct |
3 |
Correct |
64 ms |
20764 KB |
Output is correct |
4 |
Correct |
53 ms |
20248 KB |
Output is correct |
5 |
Correct |
61 ms |
20764 KB |
Output is correct |
6 |
Correct |
50 ms |
20256 KB |
Output is correct |
7 |
Correct |
65 ms |
20788 KB |
Output is correct |
8 |
Correct |
0 ms |
212 KB |
Output is correct |
9 |
Correct |
0 ms |
212 KB |
Output is correct |
10 |
Correct |
0 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
248 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
468 KB |
Output is correct |
18 |
Correct |
1 ms |
212 KB |
Output is correct |
19 |
Correct |
0 ms |
212 KB |
Output is correct |
20 |
Correct |
176 ms |
30156 KB |
Output is correct |
21 |
Correct |
166 ms |
29644 KB |
Output is correct |
22 |
Correct |
164 ms |
29708 KB |
Output is correct |
23 |
Correct |
159 ms |
30576 KB |
Output is correct |
24 |
Correct |
152 ms |
30184 KB |
Output is correct |
25 |
Correct |
174 ms |
30196 KB |
Output is correct |
26 |
Correct |
175 ms |
30188 KB |
Output is correct |
27 |
Correct |
1 ms |
340 KB |
Output is correct |
28 |
Correct |
0 ms |
212 KB |
Output is correct |
29 |
Correct |
0 ms |
212 KB |
Output is correct |
30 |
Correct |
0 ms |
212 KB |
Output is correct |
31 |
Correct |
1 ms |
328 KB |
Output is correct |
32 |
Correct |
1 ms |
212 KB |
Output is correct |
33 |
Correct |
1 ms |
212 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
1 ms |
340 KB |
Output is correct |
37 |
Correct |
0 ms |
324 KB |
Output is correct |
38 |
Correct |
1 ms |
328 KB |
Output is correct |
39 |
Correct |
0 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
340 KB |
Output is correct |
41 |
Correct |
0 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
212 KB |
Output is correct |
43 |
Correct |
1 ms |
328 KB |
Output is correct |
44 |
Correct |
1 ms |
340 KB |
Output is correct |
45 |
Correct |
1 ms |
340 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
212 KB |
Output is correct |
2 |
Correct |
58 ms |
20768 KB |
Output is correct |
3 |
Correct |
64 ms |
20764 KB |
Output is correct |
4 |
Correct |
53 ms |
20248 KB |
Output is correct |
5 |
Correct |
61 ms |
20764 KB |
Output is correct |
6 |
Correct |
50 ms |
20256 KB |
Output is correct |
7 |
Correct |
65 ms |
20788 KB |
Output is correct |
8 |
Correct |
0 ms |
212 KB |
Output is correct |
9 |
Correct |
0 ms |
212 KB |
Output is correct |
10 |
Correct |
0 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
248 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
468 KB |
Output is correct |
18 |
Correct |
1 ms |
212 KB |
Output is correct |
19 |
Correct |
0 ms |
212 KB |
Output is correct |
20 |
Correct |
176 ms |
30156 KB |
Output is correct |
21 |
Correct |
166 ms |
29644 KB |
Output is correct |
22 |
Correct |
164 ms |
29708 KB |
Output is correct |
23 |
Correct |
159 ms |
30576 KB |
Output is correct |
24 |
Correct |
152 ms |
30184 KB |
Output is correct |
25 |
Correct |
174 ms |
30196 KB |
Output is correct |
26 |
Correct |
175 ms |
30188 KB |
Output is correct |
27 |
Correct |
1 ms |
340 KB |
Output is correct |
28 |
Correct |
0 ms |
212 KB |
Output is correct |
29 |
Correct |
0 ms |
212 KB |
Output is correct |
30 |
Correct |
0 ms |
212 KB |
Output is correct |
31 |
Correct |
1 ms |
328 KB |
Output is correct |
32 |
Correct |
1 ms |
212 KB |
Output is correct |
33 |
Correct |
1 ms |
212 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
1 ms |
340 KB |
Output is correct |
37 |
Correct |
0 ms |
324 KB |
Output is correct |
38 |
Correct |
1 ms |
328 KB |
Output is correct |
39 |
Correct |
0 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
340 KB |
Output is correct |
41 |
Correct |
0 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
212 KB |
Output is correct |
43 |
Correct |
1 ms |
328 KB |
Output is correct |
44 |
Correct |
1 ms |
340 KB |
Output is correct |
45 |
Correct |
1 ms |
340 KB |
Output is correct |
46 |
Correct |
1 ms |
304 KB |
Output is correct |
47 |
Correct |
244 ms |
37420 KB |
Output is correct |
48 |
Correct |
267 ms |
36832 KB |
Output is correct |
49 |
Correct |
224 ms |
36668 KB |
Output is correct |
50 |
Correct |
214 ms |
37700 KB |
Output is correct |
51 |
Correct |
203 ms |
37360 KB |
Output is correct |
52 |
Correct |
231 ms |
37320 KB |
Output is correct |
53 |
Correct |
237 ms |
37700 KB |
Output is correct |
54 |
Correct |
3 ms |
340 KB |
Output is correct |
55 |
Correct |
3 ms |
340 KB |
Output is correct |
56 |
Correct |
4 ms |
340 KB |
Output is correct |
57 |
Correct |
4 ms |
452 KB |
Output is correct |
58 |
Correct |
4 ms |
452 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
212 KB |
Output is correct |
2 |
Correct |
58 ms |
20768 KB |
Output is correct |
3 |
Correct |
64 ms |
20764 KB |
Output is correct |
4 |
Correct |
53 ms |
20248 KB |
Output is correct |
5 |
Correct |
61 ms |
20764 KB |
Output is correct |
6 |
Correct |
50 ms |
20256 KB |
Output is correct |
7 |
Correct |
65 ms |
20788 KB |
Output is correct |
8 |
Correct |
0 ms |
212 KB |
Output is correct |
9 |
Correct |
0 ms |
212 KB |
Output is correct |
10 |
Correct |
0 ms |
212 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
1 ms |
248 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
1 ms |
212 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
340 KB |
Output is correct |
17 |
Correct |
1 ms |
468 KB |
Output is correct |
18 |
Correct |
1 ms |
212 KB |
Output is correct |
19 |
Correct |
0 ms |
212 KB |
Output is correct |
20 |
Correct |
176 ms |
30156 KB |
Output is correct |
21 |
Correct |
166 ms |
29644 KB |
Output is correct |
22 |
Correct |
164 ms |
29708 KB |
Output is correct |
23 |
Correct |
159 ms |
30576 KB |
Output is correct |
24 |
Correct |
152 ms |
30184 KB |
Output is correct |
25 |
Correct |
174 ms |
30196 KB |
Output is correct |
26 |
Correct |
175 ms |
30188 KB |
Output is correct |
27 |
Correct |
1 ms |
340 KB |
Output is correct |
28 |
Correct |
0 ms |
212 KB |
Output is correct |
29 |
Correct |
0 ms |
212 KB |
Output is correct |
30 |
Correct |
0 ms |
212 KB |
Output is correct |
31 |
Correct |
1 ms |
328 KB |
Output is correct |
32 |
Correct |
1 ms |
212 KB |
Output is correct |
33 |
Correct |
1 ms |
212 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
1 ms |
340 KB |
Output is correct |
37 |
Correct |
0 ms |
324 KB |
Output is correct |
38 |
Correct |
1 ms |
328 KB |
Output is correct |
39 |
Correct |
0 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
340 KB |
Output is correct |
41 |
Correct |
0 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
212 KB |
Output is correct |
43 |
Correct |
1 ms |
328 KB |
Output is correct |
44 |
Correct |
1 ms |
340 KB |
Output is correct |
45 |
Correct |
1 ms |
340 KB |
Output is correct |
46 |
Correct |
1 ms |
304 KB |
Output is correct |
47 |
Correct |
244 ms |
37420 KB |
Output is correct |
48 |
Correct |
267 ms |
36832 KB |
Output is correct |
49 |
Correct |
224 ms |
36668 KB |
Output is correct |
50 |
Correct |
214 ms |
37700 KB |
Output is correct |
51 |
Correct |
203 ms |
37360 KB |
Output is correct |
52 |
Correct |
231 ms |
37320 KB |
Output is correct |
53 |
Correct |
237 ms |
37700 KB |
Output is correct |
54 |
Correct |
3 ms |
340 KB |
Output is correct |
55 |
Correct |
3 ms |
340 KB |
Output is correct |
56 |
Correct |
4 ms |
340 KB |
Output is correct |
57 |
Correct |
4 ms |
452 KB |
Output is correct |
58 |
Correct |
4 ms |
452 KB |
Output is correct |
59 |
Correct |
277 ms |
43980 KB |
Output is correct |
60 |
Correct |
168 ms |
18016 KB |
Output is correct |
61 |
Correct |
179 ms |
19172 KB |
Output is correct |
62 |
Correct |
184 ms |
19860 KB |
Output is correct |
63 |
Correct |
304 ms |
43576 KB |
Output is correct |
64 |
Correct |
336 ms |
44748 KB |
Output is correct |
65 |
Correct |
341 ms |
44696 KB |
Output is correct |
66 |
Correct |
265 ms |
45080 KB |
Output is correct |
67 |
Correct |
260 ms |
44720 KB |
Output is correct |
68 |
Correct |
336 ms |
44748 KB |
Output is correct |
69 |
Correct |
373 ms |
45152 KB |
Output is correct |
70 |
Correct |
25 ms |
1236 KB |
Output is correct |
71 |
Correct |
25 ms |
1236 KB |
Output is correct |
72 |
Correct |
33 ms |
1236 KB |
Output is correct |
73 |
Correct |
25 ms |
1360 KB |
Output is correct |
74 |
Correct |
32 ms |
1336 KB |
Output is correct |
75 |
Correct |
52 ms |
1760 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
1 ms |
340 KB |
Output is correct |
3 |
Correct |
0 ms |
212 KB |
Output is correct |
4 |
Correct |
0 ms |
212 KB |
Output is correct |
5 |
Correct |
180 ms |
8524 KB |
Output is correct |
6 |
Correct |
155 ms |
8552 KB |
Output is correct |
7 |
Correct |
198 ms |
8512 KB |
Output is correct |
8 |
Correct |
276 ms |
8532 KB |
Output is correct |
9 |
Correct |
355 ms |
8560 KB |
Output is correct |
10 |
Correct |
235 ms |
8520 KB |
Output is correct |
11 |
Correct |
304 ms |
8512 KB |
Output is correct |
12 |
Correct |
368 ms |
8528 KB |
Output is correct |
13 |
Correct |
1 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
328 KB |
Output is correct |
15 |
Correct |
1 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
18 |
Correct |
1 ms |
328 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
0 ms |
212 KB |
Output is correct |
21 |
Correct |
0 ms |
340 KB |
Output is correct |
22 |
Correct |
1 ms |
324 KB |
Output is correct |
23 |
Correct |
0 ms |
212 KB |
Output is correct |
24 |
Correct |
0 ms |
212 KB |
Output is correct |
25 |
Correct |
0 ms |
212 KB |
Output is correct |
26 |
Correct |
1 ms |
340 KB |
Output is correct |
27 |
Correct |
0 ms |
212 KB |
Output is correct |
28 |
Correct |
1 ms |
332 KB |
Output is correct |
29 |
Correct |
1 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
212 KB |
Output is correct |
31 |
Correct |
1 ms |
340 KB |
Output is correct |
32 |
Correct |
1 ms |
212 KB |
Output is correct |
33 |
Correct |
1 ms |
328 KB |
Output is correct |
34 |
Correct |
1 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
1 ms |
212 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
1 ms |
324 KB |
Output is correct |
39 |
Correct |
1 ms |
340 KB |
Output is correct |
40 |
Correct |
1 ms |
340 KB |
Output is correct |
41 |
Correct |
3 ms |
340 KB |
Output is correct |
42 |
Correct |
3 ms |
340 KB |
Output is correct |
43 |
Correct |
4 ms |
460 KB |
Output is correct |
44 |
Correct |
4 ms |
340 KB |
Output is correct |
45 |
Correct |
4 ms |
452 KB |
Output is correct |
46 |
Correct |
21 ms |
1236 KB |
Output is correct |
47 |
Correct |
25 ms |
1236 KB |
Output is correct |
48 |
Correct |
32 ms |
1236 KB |
Output is correct |
49 |
Correct |
26 ms |
1236 KB |
Output is correct |
50 |
Correct |
31 ms |
1340 KB |
Output is correct |
51 |
Correct |
160 ms |
9004 KB |
Output is correct |
52 |
Correct |
159 ms |
8916 KB |
Output is correct |
53 |
Correct |
307 ms |
9016 KB |
Output is correct |
54 |
Correct |
386 ms |
9008 KB |
Output is correct |
55 |
Correct |
1 ms |
468 KB |
Output is correct |
56 |
Correct |
53 ms |
1788 KB |
Output is correct |
57 |
Correct |
0 ms |
212 KB |
Output is correct |
58 |
Correct |
58 ms |
20768 KB |
Output is correct |
59 |
Correct |
64 ms |
20764 KB |
Output is correct |
60 |
Correct |
53 ms |
20248 KB |
Output is correct |
61 |
Correct |
61 ms |
20764 KB |
Output is correct |
62 |
Correct |
50 ms |
20256 KB |
Output is correct |
63 |
Correct |
65 ms |
20788 KB |
Output is correct |
64 |
Correct |
0 ms |
212 KB |
Output is correct |
65 |
Correct |
0 ms |
212 KB |
Output is correct |
66 |
Correct |
0 ms |
212 KB |
Output is correct |
67 |
Correct |
1 ms |
212 KB |
Output is correct |
68 |
Correct |
1 ms |
248 KB |
Output is correct |
69 |
Correct |
1 ms |
212 KB |
Output is correct |
70 |
Correct |
1 ms |
212 KB |
Output is correct |
71 |
Correct |
1 ms |
212 KB |
Output is correct |
72 |
Correct |
0 ms |
340 KB |
Output is correct |
73 |
Correct |
1 ms |
468 KB |
Output is correct |
74 |
Correct |
1 ms |
212 KB |
Output is correct |
75 |
Correct |
0 ms |
212 KB |
Output is correct |
76 |
Correct |
176 ms |
30156 KB |
Output is correct |
77 |
Correct |
166 ms |
29644 KB |
Output is correct |
78 |
Correct |
164 ms |
29708 KB |
Output is correct |
79 |
Correct |
159 ms |
30576 KB |
Output is correct |
80 |
Correct |
152 ms |
30184 KB |
Output is correct |
81 |
Correct |
174 ms |
30196 KB |
Output is correct |
82 |
Correct |
175 ms |
30188 KB |
Output is correct |
83 |
Correct |
1 ms |
340 KB |
Output is correct |
84 |
Correct |
0 ms |
212 KB |
Output is correct |
85 |
Correct |
0 ms |
212 KB |
Output is correct |
86 |
Correct |
0 ms |
212 KB |
Output is correct |
87 |
Correct |
1 ms |
328 KB |
Output is correct |
88 |
Correct |
1 ms |
212 KB |
Output is correct |
89 |
Correct |
1 ms |
212 KB |
Output is correct |
90 |
Correct |
1 ms |
212 KB |
Output is correct |
91 |
Correct |
1 ms |
340 KB |
Output is correct |
92 |
Correct |
1 ms |
340 KB |
Output is correct |
93 |
Correct |
0 ms |
324 KB |
Output is correct |
94 |
Correct |
1 ms |
328 KB |
Output is correct |
95 |
Correct |
0 ms |
212 KB |
Output is correct |
96 |
Correct |
1 ms |
340 KB |
Output is correct |
97 |
Correct |
0 ms |
212 KB |
Output is correct |
98 |
Correct |
1 ms |
212 KB |
Output is correct |
99 |
Correct |
1 ms |
328 KB |
Output is correct |
100 |
Correct |
1 ms |
340 KB |
Output is correct |
101 |
Correct |
1 ms |
340 KB |
Output is correct |
102 |
Correct |
1 ms |
304 KB |
Output is correct |
103 |
Correct |
244 ms |
37420 KB |
Output is correct |
104 |
Correct |
267 ms |
36832 KB |
Output is correct |
105 |
Correct |
224 ms |
36668 KB |
Output is correct |
106 |
Correct |
214 ms |
37700 KB |
Output is correct |
107 |
Correct |
203 ms |
37360 KB |
Output is correct |
108 |
Correct |
231 ms |
37320 KB |
Output is correct |
109 |
Correct |
237 ms |
37700 KB |
Output is correct |
110 |
Correct |
3 ms |
340 KB |
Output is correct |
111 |
Correct |
3 ms |
340 KB |
Output is correct |
112 |
Correct |
4 ms |
340 KB |
Output is correct |
113 |
Correct |
4 ms |
452 KB |
Output is correct |
114 |
Correct |
4 ms |
452 KB |
Output is correct |
115 |
Correct |
277 ms |
43980 KB |
Output is correct |
116 |
Correct |
168 ms |
18016 KB |
Output is correct |
117 |
Correct |
179 ms |
19172 KB |
Output is correct |
118 |
Correct |
184 ms |
19860 KB |
Output is correct |
119 |
Correct |
304 ms |
43576 KB |
Output is correct |
120 |
Correct |
336 ms |
44748 KB |
Output is correct |
121 |
Correct |
341 ms |
44696 KB |
Output is correct |
122 |
Correct |
265 ms |
45080 KB |
Output is correct |
123 |
Correct |
260 ms |
44720 KB |
Output is correct |
124 |
Correct |
336 ms |
44748 KB |
Output is correct |
125 |
Correct |
373 ms |
45152 KB |
Output is correct |
126 |
Correct |
25 ms |
1236 KB |
Output is correct |
127 |
Correct |
25 ms |
1236 KB |
Output is correct |
128 |
Correct |
33 ms |
1236 KB |
Output is correct |
129 |
Correct |
25 ms |
1360 KB |
Output is correct |
130 |
Correct |
32 ms |
1336 KB |
Output is correct |
131 |
Correct |
52 ms |
1760 KB |
Output is correct |
132 |
Correct |
861 ms |
58712 KB |
Output is correct |
133 |
Correct |
849 ms |
58488 KB |
Output is correct |
134 |
Correct |
861 ms |
58660 KB |
Output is correct |
135 |
Correct |
849 ms |
58612 KB |
Output is correct |
136 |
Correct |
875 ms |
58584 KB |
Output is correct |
137 |
Correct |
569 ms |
53772 KB |
Output is correct |
138 |
Correct |
550 ms |
53940 KB |
Output is correct |
139 |
Correct |
439 ms |
58712 KB |
Output is correct |
140 |
Correct |
433 ms |
58400 KB |
Output is correct |
141 |
Correct |
959 ms |
58328 KB |
Output is correct |
142 |
Correct |
949 ms |
58768 KB |
Output is correct |