#include <bits/stdc++.h>
using namespace std;
const int N = 300001;
const int M = 20;
const int to = 1024;
int a[N], sum[M], ans[N], mn[N], masks[N];
int dp[to][to], ppcnt[to][to];
short l[1<<M], r[1<<M];
void smin(int & x, int y){
if(x>y)x=y;
}
int main()
{
ios_base::sync_with_stdio(0);
cin.tie(0);
int n, m;
cin >> n >> m;
for(int i=0; i< n; i++){
for(int j=0; j< m; j++){
int x;
cin >> x;
a[i]+=x<<j;
sum[j]+=x;
}
}
for(int i=0; i< n; i++)mn[i]=1e9;
for(int i=0; i< n; i++){
for(int j=0; j< m; j++)sum[j]-=(a[i] & (1<<j))>>j;
for(int j=0; j< m; j++){
if(sum[j]>=n/2)ans[i]++;
if(sum[j]==n/2)masks[i]+=1<<j;
}
for(int j=0; j< m; j++)sum[j]+=(a[i] & (1<<j))>>j;
}
for(int i=0; i< (1<<M); ++i){
l[i]=i>>10;
r[i]=i & ((1<<10)-1);
short f = l[i], s = r[i];
dp[f][s]=1e9;
ppcnt[f][s]=__builtin_popcount(f & s);
}
for(int i=0; i< n-1; ++i){
short f = l[a[i]];
short s = r[a[i]];
for(short j = 0; j<(1<<(max(0, m-10))); ++j){
smin(dp[j][s], ppcnt[j][f]);
}
f = l[masks[i+1]];
s = r[masks[i+1]];
for(short j=0; j<to; ++j){
smin(mn[i+1], dp[f][j]+ppcnt[s][j]);
}
}
for(int i=0; i< (1<<M); ++i)dp[l[i]][r[i]]=1e9;
for(int i=n-1; i>0; i--){
short f = l[a[i]];
short s = r[a[i]];
for(short j = 0; j<(1<<(max(0, m-10))); ++j){
smin(dp[j][s], ppcnt[j][f]);
}
f = l[masks[i-1]];
s = r[masks[i-1]];
for(short j=0; j<to; ++j){
smin(mn[i-1], dp[f][j]+ppcnt[s][j]);
}
}
for(int i=0; i< n; i++){
cout << ans[i]-mn[i] << '\n';
}
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
6 ms |
16988 KB |
Output is correct |
2 |
Correct |
6 ms |
16988 KB |
Output is correct |
3 |
Correct |
5 ms |
16988 KB |
Output is correct |
4 |
Correct |
5 ms |
17032 KB |
Output is correct |
5 |
Correct |
7 ms |
16988 KB |
Output is correct |
6 |
Correct |
18 ms |
16988 KB |
Output is correct |
7 |
Correct |
6 ms |
16988 KB |
Output is correct |
8 |
Correct |
7 ms |
16988 KB |
Output is correct |
9 |
Correct |
18 ms |
17060 KB |
Output is correct |
10 |
Correct |
6 ms |
16988 KB |
Output is correct |
11 |
Correct |
6 ms |
16988 KB |
Output is correct |
12 |
Correct |
18 ms |
17056 KB |
Output is correct |
13 |
Correct |
6 ms |
16988 KB |
Output is correct |
14 |
Correct |
6 ms |
16988 KB |
Output is correct |
15 |
Correct |
6 ms |
16988 KB |
Output is correct |
16 |
Correct |
10 ms |
16988 KB |
Output is correct |
17 |
Correct |
7 ms |
16988 KB |
Output is correct |
18 |
Correct |
5 ms |
17052 KB |
Output is correct |
19 |
Correct |
5 ms |
16988 KB |
Output is correct |
20 |
Correct |
5 ms |
16988 KB |
Output is correct |
21 |
Correct |
6 ms |
16988 KB |
Output is correct |
22 |
Correct |
7 ms |
17056 KB |
Output is correct |
23 |
Correct |
5 ms |
16988 KB |
Output is correct |
24 |
Correct |
5 ms |
16988 KB |
Output is correct |
25 |
Correct |
5 ms |
16988 KB |
Output is correct |
26 |
Correct |
6 ms |
16988 KB |
Output is correct |
27 |
Correct |
6 ms |
16988 KB |
Output is correct |
28 |
Correct |
6 ms |
17052 KB |
Output is correct |
29 |
Correct |
5 ms |
16988 KB |
Output is correct |
30 |
Correct |
6 ms |
16984 KB |
Output is correct |
31 |
Correct |
9 ms |
16988 KB |
Output is correct |
32 |
Correct |
6 ms |
16988 KB |
Output is correct |
33 |
Correct |
6 ms |
17044 KB |
Output is correct |
34 |
Correct |
6 ms |
16984 KB |
Output is correct |
35 |
Correct |
6 ms |
16984 KB |
Output is correct |
36 |
Correct |
6 ms |
16988 KB |
Output is correct |
37 |
Correct |
6 ms |
17056 KB |
Output is correct |
38 |
Correct |
6 ms |
17056 KB |
Output is correct |
39 |
Correct |
6 ms |
16984 KB |
Output is correct |
40 |
Correct |
7 ms |
16988 KB |
Output is correct |
41 |
Correct |
6 ms |
16988 KB |
Output is correct |
42 |
Correct |
5 ms |
16984 KB |
Output is correct |
43 |
Correct |
5 ms |
16988 KB |
Output is correct |
44 |
Correct |
6 ms |
16988 KB |
Output is correct |
45 |
Correct |
5 ms |
16988 KB |
Output is correct |
46 |
Correct |
6 ms |
16988 KB |
Output is correct |
47 |
Correct |
5 ms |
16988 KB |
Output is correct |
48 |
Correct |
5 ms |
16988 KB |
Output is correct |
49 |
Correct |
8 ms |
16988 KB |
Output is correct |
50 |
Correct |
7 ms |
16988 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
6 ms |
16988 KB |
Output is correct |
2 |
Correct |
6 ms |
16988 KB |
Output is correct |
3 |
Correct |
5 ms |
16988 KB |
Output is correct |
4 |
Correct |
5 ms |
17032 KB |
Output is correct |
5 |
Correct |
7 ms |
16988 KB |
Output is correct |
6 |
Correct |
18 ms |
16988 KB |
Output is correct |
7 |
Correct |
6 ms |
16988 KB |
Output is correct |
8 |
Correct |
7 ms |
16988 KB |
Output is correct |
9 |
Correct |
18 ms |
17060 KB |
Output is correct |
10 |
Correct |
6 ms |
16988 KB |
Output is correct |
11 |
Correct |
6 ms |
16988 KB |
Output is correct |
12 |
Correct |
18 ms |
17056 KB |
Output is correct |
13 |
Correct |
6 ms |
16988 KB |
Output is correct |
14 |
Correct |
6 ms |
16988 KB |
Output is correct |
15 |
Correct |
6 ms |
16988 KB |
Output is correct |
16 |
Correct |
10 ms |
16988 KB |
Output is correct |
17 |
Correct |
7 ms |
16988 KB |
Output is correct |
18 |
Correct |
5 ms |
17052 KB |
Output is correct |
19 |
Correct |
5 ms |
16988 KB |
Output is correct |
20 |
Correct |
5 ms |
16988 KB |
Output is correct |
21 |
Correct |
6 ms |
16988 KB |
Output is correct |
22 |
Correct |
7 ms |
17056 KB |
Output is correct |
23 |
Correct |
5 ms |
16988 KB |
Output is correct |
24 |
Correct |
5 ms |
16988 KB |
Output is correct |
25 |
Correct |
5 ms |
16988 KB |
Output is correct |
26 |
Correct |
6 ms |
16988 KB |
Output is correct |
27 |
Correct |
6 ms |
16988 KB |
Output is correct |
28 |
Correct |
6 ms |
17052 KB |
Output is correct |
29 |
Correct |
5 ms |
16988 KB |
Output is correct |
30 |
Correct |
6 ms |
16984 KB |
Output is correct |
31 |
Correct |
9 ms |
16988 KB |
Output is correct |
32 |
Correct |
6 ms |
16988 KB |
Output is correct |
33 |
Correct |
6 ms |
17044 KB |
Output is correct |
34 |
Correct |
6 ms |
16984 KB |
Output is correct |
35 |
Correct |
6 ms |
16984 KB |
Output is correct |
36 |
Correct |
6 ms |
16988 KB |
Output is correct |
37 |
Correct |
6 ms |
17056 KB |
Output is correct |
38 |
Correct |
6 ms |
17056 KB |
Output is correct |
39 |
Correct |
6 ms |
16984 KB |
Output is correct |
40 |
Correct |
7 ms |
16988 KB |
Output is correct |
41 |
Correct |
6 ms |
16988 KB |
Output is correct |
42 |
Correct |
5 ms |
16984 KB |
Output is correct |
43 |
Correct |
5 ms |
16988 KB |
Output is correct |
44 |
Correct |
6 ms |
16988 KB |
Output is correct |
45 |
Correct |
5 ms |
16988 KB |
Output is correct |
46 |
Correct |
6 ms |
16988 KB |
Output is correct |
47 |
Correct |
5 ms |
16988 KB |
Output is correct |
48 |
Correct |
5 ms |
16988 KB |
Output is correct |
49 |
Correct |
8 ms |
16988 KB |
Output is correct |
50 |
Correct |
7 ms |
16988 KB |
Output is correct |
51 |
Correct |
110 ms |
17048 KB |
Output is correct |
52 |
Correct |
112 ms |
16984 KB |
Output is correct |
53 |
Correct |
95 ms |
17036 KB |
Output is correct |
54 |
Correct |
93 ms |
16984 KB |
Output is correct |
55 |
Correct |
12 ms |
16984 KB |
Output is correct |
56 |
Correct |
22 ms |
17060 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
5 ms |
16984 KB |
Output is correct |
2 |
Correct |
705 ms |
18004 KB |
Output is correct |
3 |
Correct |
699 ms |
17864 KB |
Output is correct |
4 |
Correct |
665 ms |
17956 KB |
Output is correct |
5 |
Correct |
640 ms |
17952 KB |
Output is correct |
6 |
Correct |
684 ms |
17956 KB |
Output is correct |
7 |
Correct |
648 ms |
17952 KB |
Output is correct |
8 |
Correct |
5 ms |
17052 KB |
Output is correct |
9 |
Correct |
6 ms |
16964 KB |
Output is correct |
10 |
Correct |
5 ms |
16988 KB |
Output is correct |
11 |
Correct |
6 ms |
16988 KB |
Output is correct |
12 |
Correct |
6 ms |
17056 KB |
Output is correct |
13 |
Correct |
5 ms |
17056 KB |
Output is correct |
14 |
Correct |
6 ms |
16988 KB |
Output is correct |
15 |
Correct |
5 ms |
16988 KB |
Output is correct |
16 |
Correct |
6 ms |
16988 KB |
Output is correct |
17 |
Correct |
12 ms |
17056 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
5 ms |
16984 KB |
Output is correct |
2 |
Correct |
705 ms |
18004 KB |
Output is correct |
3 |
Correct |
699 ms |
17864 KB |
Output is correct |
4 |
Correct |
665 ms |
17956 KB |
Output is correct |
5 |
Correct |
640 ms |
17952 KB |
Output is correct |
6 |
Correct |
684 ms |
17956 KB |
Output is correct |
7 |
Correct |
648 ms |
17952 KB |
Output is correct |
8 |
Correct |
5 ms |
17052 KB |
Output is correct |
9 |
Correct |
6 ms |
16964 KB |
Output is correct |
10 |
Correct |
5 ms |
16988 KB |
Output is correct |
11 |
Correct |
6 ms |
16988 KB |
Output is correct |
12 |
Correct |
6 ms |
17056 KB |
Output is correct |
13 |
Correct |
5 ms |
17056 KB |
Output is correct |
14 |
Correct |
6 ms |
16988 KB |
Output is correct |
15 |
Correct |
5 ms |
16988 KB |
Output is correct |
16 |
Correct |
6 ms |
16988 KB |
Output is correct |
17 |
Correct |
12 ms |
17056 KB |
Output is correct |
18 |
Correct |
5 ms |
16984 KB |
Output is correct |
19 |
Correct |
6 ms |
16988 KB |
Output is correct |
20 |
Correct |
768 ms |
17864 KB |
Output is correct |
21 |
Correct |
822 ms |
18004 KB |
Output is correct |
22 |
Correct |
817 ms |
17852 KB |
Output is correct |
23 |
Correct |
785 ms |
18120 KB |
Output is correct |
24 |
Correct |
794 ms |
18004 KB |
Output is correct |
25 |
Correct |
739 ms |
17848 KB |
Output is correct |
26 |
Correct |
771 ms |
17852 KB |
Output is correct |
27 |
Correct |
9 ms |
16988 KB |
Output is correct |
28 |
Correct |
6 ms |
16988 KB |
Output is correct |
29 |
Correct |
6 ms |
16988 KB |
Output is correct |
30 |
Correct |
6 ms |
16988 KB |
Output is correct |
31 |
Correct |
7 ms |
16988 KB |
Output is correct |
32 |
Correct |
6 ms |
16988 KB |
Output is correct |
33 |
Correct |
6 ms |
17056 KB |
Output is correct |
34 |
Correct |
6 ms |
16988 KB |
Output is correct |
35 |
Correct |
6 ms |
16988 KB |
Output is correct |
36 |
Correct |
6 ms |
16984 KB |
Output is correct |
37 |
Correct |
6 ms |
16988 KB |
Output is correct |
38 |
Correct |
6 ms |
16988 KB |
Output is correct |
39 |
Correct |
7 ms |
16988 KB |
Output is correct |
40 |
Correct |
6 ms |
16988 KB |
Output is correct |
41 |
Correct |
6 ms |
16988 KB |
Output is correct |
42 |
Correct |
6 ms |
16848 KB |
Output is correct |
43 |
Correct |
6 ms |
16988 KB |
Output is correct |
44 |
Correct |
6 ms |
16988 KB |
Output is correct |
45 |
Correct |
13 ms |
16988 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
5 ms |
16984 KB |
Output is correct |
2 |
Correct |
705 ms |
18004 KB |
Output is correct |
3 |
Correct |
699 ms |
17864 KB |
Output is correct |
4 |
Correct |
665 ms |
17956 KB |
Output is correct |
5 |
Correct |
640 ms |
17952 KB |
Output is correct |
6 |
Correct |
684 ms |
17956 KB |
Output is correct |
7 |
Correct |
648 ms |
17952 KB |
Output is correct |
8 |
Correct |
5 ms |
17052 KB |
Output is correct |
9 |
Correct |
6 ms |
16964 KB |
Output is correct |
10 |
Correct |
5 ms |
16988 KB |
Output is correct |
11 |
Correct |
6 ms |
16988 KB |
Output is correct |
12 |
Correct |
6 ms |
17056 KB |
Output is correct |
13 |
Correct |
5 ms |
17056 KB |
Output is correct |
14 |
Correct |
6 ms |
16988 KB |
Output is correct |
15 |
Correct |
5 ms |
16988 KB |
Output is correct |
16 |
Correct |
6 ms |
16988 KB |
Output is correct |
17 |
Correct |
12 ms |
17056 KB |
Output is correct |
18 |
Correct |
5 ms |
16984 KB |
Output is correct |
19 |
Correct |
6 ms |
16988 KB |
Output is correct |
20 |
Correct |
768 ms |
17864 KB |
Output is correct |
21 |
Correct |
822 ms |
18004 KB |
Output is correct |
22 |
Correct |
817 ms |
17852 KB |
Output is correct |
23 |
Correct |
785 ms |
18120 KB |
Output is correct |
24 |
Correct |
794 ms |
18004 KB |
Output is correct |
25 |
Correct |
739 ms |
17848 KB |
Output is correct |
26 |
Correct |
771 ms |
17852 KB |
Output is correct |
27 |
Correct |
9 ms |
16988 KB |
Output is correct |
28 |
Correct |
6 ms |
16988 KB |
Output is correct |
29 |
Correct |
6 ms |
16988 KB |
Output is correct |
30 |
Correct |
6 ms |
16988 KB |
Output is correct |
31 |
Correct |
7 ms |
16988 KB |
Output is correct |
32 |
Correct |
6 ms |
16988 KB |
Output is correct |
33 |
Correct |
6 ms |
17056 KB |
Output is correct |
34 |
Correct |
6 ms |
16988 KB |
Output is correct |
35 |
Correct |
6 ms |
16988 KB |
Output is correct |
36 |
Correct |
6 ms |
16984 KB |
Output is correct |
37 |
Correct |
6 ms |
16988 KB |
Output is correct |
38 |
Correct |
6 ms |
16988 KB |
Output is correct |
39 |
Correct |
7 ms |
16988 KB |
Output is correct |
40 |
Correct |
6 ms |
16988 KB |
Output is correct |
41 |
Correct |
6 ms |
16988 KB |
Output is correct |
42 |
Correct |
6 ms |
16848 KB |
Output is correct |
43 |
Correct |
6 ms |
16988 KB |
Output is correct |
44 |
Correct |
6 ms |
16988 KB |
Output is correct |
45 |
Correct |
13 ms |
16988 KB |
Output is correct |
46 |
Correct |
6 ms |
16984 KB |
Output is correct |
47 |
Correct |
892 ms |
17952 KB |
Output is correct |
48 |
Correct |
837 ms |
18004 KB |
Output is correct |
49 |
Correct |
850 ms |
18004 KB |
Output is correct |
50 |
Correct |
812 ms |
18208 KB |
Output is correct |
51 |
Correct |
816 ms |
17848 KB |
Output is correct |
52 |
Correct |
825 ms |
17868 KB |
Output is correct |
53 |
Correct |
869 ms |
18256 KB |
Output is correct |
54 |
Correct |
5 ms |
16988 KB |
Output is correct |
55 |
Correct |
6 ms |
16988 KB |
Output is correct |
56 |
Correct |
6 ms |
17056 KB |
Output is correct |
57 |
Correct |
6 ms |
16984 KB |
Output is correct |
58 |
Correct |
6 ms |
16984 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
5 ms |
16984 KB |
Output is correct |
2 |
Correct |
705 ms |
18004 KB |
Output is correct |
3 |
Correct |
699 ms |
17864 KB |
Output is correct |
4 |
Correct |
665 ms |
17956 KB |
Output is correct |
5 |
Correct |
640 ms |
17952 KB |
Output is correct |
6 |
Correct |
684 ms |
17956 KB |
Output is correct |
7 |
Correct |
648 ms |
17952 KB |
Output is correct |
8 |
Correct |
5 ms |
17052 KB |
Output is correct |
9 |
Correct |
6 ms |
16964 KB |
Output is correct |
10 |
Correct |
5 ms |
16988 KB |
Output is correct |
11 |
Correct |
6 ms |
16988 KB |
Output is correct |
12 |
Correct |
6 ms |
17056 KB |
Output is correct |
13 |
Correct |
5 ms |
17056 KB |
Output is correct |
14 |
Correct |
6 ms |
16988 KB |
Output is correct |
15 |
Correct |
5 ms |
16988 KB |
Output is correct |
16 |
Correct |
6 ms |
16988 KB |
Output is correct |
17 |
Correct |
12 ms |
17056 KB |
Output is correct |
18 |
Correct |
5 ms |
16984 KB |
Output is correct |
19 |
Correct |
6 ms |
16988 KB |
Output is correct |
20 |
Correct |
768 ms |
17864 KB |
Output is correct |
21 |
Correct |
822 ms |
18004 KB |
Output is correct |
22 |
Correct |
817 ms |
17852 KB |
Output is correct |
23 |
Correct |
785 ms |
18120 KB |
Output is correct |
24 |
Correct |
794 ms |
18004 KB |
Output is correct |
25 |
Correct |
739 ms |
17848 KB |
Output is correct |
26 |
Correct |
771 ms |
17852 KB |
Output is correct |
27 |
Correct |
9 ms |
16988 KB |
Output is correct |
28 |
Correct |
6 ms |
16988 KB |
Output is correct |
29 |
Correct |
6 ms |
16988 KB |
Output is correct |
30 |
Correct |
6 ms |
16988 KB |
Output is correct |
31 |
Correct |
7 ms |
16988 KB |
Output is correct |
32 |
Correct |
6 ms |
16988 KB |
Output is correct |
33 |
Correct |
6 ms |
17056 KB |
Output is correct |
34 |
Correct |
6 ms |
16988 KB |
Output is correct |
35 |
Correct |
6 ms |
16988 KB |
Output is correct |
36 |
Correct |
6 ms |
16984 KB |
Output is correct |
37 |
Correct |
6 ms |
16988 KB |
Output is correct |
38 |
Correct |
6 ms |
16988 KB |
Output is correct |
39 |
Correct |
7 ms |
16988 KB |
Output is correct |
40 |
Correct |
6 ms |
16988 KB |
Output is correct |
41 |
Correct |
6 ms |
16988 KB |
Output is correct |
42 |
Correct |
6 ms |
16848 KB |
Output is correct |
43 |
Correct |
6 ms |
16988 KB |
Output is correct |
44 |
Correct |
6 ms |
16988 KB |
Output is correct |
45 |
Correct |
13 ms |
16988 KB |
Output is correct |
46 |
Correct |
6 ms |
16984 KB |
Output is correct |
47 |
Correct |
892 ms |
17952 KB |
Output is correct |
48 |
Correct |
837 ms |
18004 KB |
Output is correct |
49 |
Correct |
850 ms |
18004 KB |
Output is correct |
50 |
Correct |
812 ms |
18208 KB |
Output is correct |
51 |
Correct |
816 ms |
17848 KB |
Output is correct |
52 |
Correct |
825 ms |
17868 KB |
Output is correct |
53 |
Correct |
869 ms |
18256 KB |
Output is correct |
54 |
Correct |
5 ms |
16988 KB |
Output is correct |
55 |
Correct |
6 ms |
16988 KB |
Output is correct |
56 |
Correct |
6 ms |
17056 KB |
Output is correct |
57 |
Correct |
6 ms |
16984 KB |
Output is correct |
58 |
Correct |
6 ms |
16984 KB |
Output is correct |
59 |
Correct |
1008 ms |
18208 KB |
Output is correct |
60 |
Correct |
485 ms |
17492 KB |
Output is correct |
61 |
Correct |
519 ms |
17236 KB |
Output is correct |
62 |
Correct |
522 ms |
17232 KB |
Output is correct |
63 |
Correct |
1043 ms |
18000 KB |
Output is correct |
64 |
Correct |
1264 ms |
18000 KB |
Output is correct |
65 |
Correct |
1259 ms |
17956 KB |
Output is correct |
66 |
Correct |
1157 ms |
18212 KB |
Output is correct |
67 |
Correct |
1305 ms |
18000 KB |
Output is correct |
68 |
Correct |
1214 ms |
18000 KB |
Output is correct |
69 |
Correct |
1223 ms |
18256 KB |
Output is correct |
70 |
Correct |
8 ms |
16984 KB |
Output is correct |
71 |
Correct |
7 ms |
16988 KB |
Output is correct |
72 |
Correct |
6 ms |
16988 KB |
Output is correct |
73 |
Correct |
6 ms |
16988 KB |
Output is correct |
74 |
Correct |
6 ms |
16988 KB |
Output is correct |
75 |
Correct |
26 ms |
16988 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
6 ms |
16988 KB |
Output is correct |
2 |
Correct |
6 ms |
16988 KB |
Output is correct |
3 |
Correct |
5 ms |
16988 KB |
Output is correct |
4 |
Correct |
5 ms |
17032 KB |
Output is correct |
5 |
Correct |
7 ms |
16988 KB |
Output is correct |
6 |
Correct |
18 ms |
16988 KB |
Output is correct |
7 |
Correct |
6 ms |
16988 KB |
Output is correct |
8 |
Correct |
7 ms |
16988 KB |
Output is correct |
9 |
Correct |
18 ms |
17060 KB |
Output is correct |
10 |
Correct |
6 ms |
16988 KB |
Output is correct |
11 |
Correct |
6 ms |
16988 KB |
Output is correct |
12 |
Correct |
18 ms |
17056 KB |
Output is correct |
13 |
Correct |
6 ms |
16988 KB |
Output is correct |
14 |
Correct |
6 ms |
16988 KB |
Output is correct |
15 |
Correct |
6 ms |
16988 KB |
Output is correct |
16 |
Correct |
10 ms |
16988 KB |
Output is correct |
17 |
Correct |
7 ms |
16988 KB |
Output is correct |
18 |
Correct |
5 ms |
17052 KB |
Output is correct |
19 |
Correct |
5 ms |
16988 KB |
Output is correct |
20 |
Correct |
5 ms |
16988 KB |
Output is correct |
21 |
Correct |
6 ms |
16988 KB |
Output is correct |
22 |
Correct |
7 ms |
17056 KB |
Output is correct |
23 |
Correct |
5 ms |
16988 KB |
Output is correct |
24 |
Correct |
5 ms |
16988 KB |
Output is correct |
25 |
Correct |
5 ms |
16988 KB |
Output is correct |
26 |
Correct |
6 ms |
16988 KB |
Output is correct |
27 |
Correct |
6 ms |
16988 KB |
Output is correct |
28 |
Correct |
6 ms |
17052 KB |
Output is correct |
29 |
Correct |
5 ms |
16988 KB |
Output is correct |
30 |
Correct |
6 ms |
16984 KB |
Output is correct |
31 |
Correct |
9 ms |
16988 KB |
Output is correct |
32 |
Correct |
6 ms |
16988 KB |
Output is correct |
33 |
Correct |
6 ms |
17044 KB |
Output is correct |
34 |
Correct |
6 ms |
16984 KB |
Output is correct |
35 |
Correct |
6 ms |
16984 KB |
Output is correct |
36 |
Correct |
6 ms |
16988 KB |
Output is correct |
37 |
Correct |
6 ms |
17056 KB |
Output is correct |
38 |
Correct |
6 ms |
17056 KB |
Output is correct |
39 |
Correct |
6 ms |
16984 KB |
Output is correct |
40 |
Correct |
7 ms |
16988 KB |
Output is correct |
41 |
Correct |
6 ms |
16988 KB |
Output is correct |
42 |
Correct |
5 ms |
16984 KB |
Output is correct |
43 |
Correct |
5 ms |
16988 KB |
Output is correct |
44 |
Correct |
6 ms |
16988 KB |
Output is correct |
45 |
Correct |
5 ms |
16988 KB |
Output is correct |
46 |
Correct |
6 ms |
16988 KB |
Output is correct |
47 |
Correct |
5 ms |
16988 KB |
Output is correct |
48 |
Correct |
5 ms |
16988 KB |
Output is correct |
49 |
Correct |
8 ms |
16988 KB |
Output is correct |
50 |
Correct |
7 ms |
16988 KB |
Output is correct |
51 |
Correct |
110 ms |
17048 KB |
Output is correct |
52 |
Correct |
112 ms |
16984 KB |
Output is correct |
53 |
Correct |
95 ms |
17036 KB |
Output is correct |
54 |
Correct |
93 ms |
16984 KB |
Output is correct |
55 |
Correct |
12 ms |
16984 KB |
Output is correct |
56 |
Correct |
22 ms |
17060 KB |
Output is correct |
57 |
Correct |
5 ms |
16984 KB |
Output is correct |
58 |
Correct |
705 ms |
18004 KB |
Output is correct |
59 |
Correct |
699 ms |
17864 KB |
Output is correct |
60 |
Correct |
665 ms |
17956 KB |
Output is correct |
61 |
Correct |
640 ms |
17952 KB |
Output is correct |
62 |
Correct |
684 ms |
17956 KB |
Output is correct |
63 |
Correct |
648 ms |
17952 KB |
Output is correct |
64 |
Correct |
5 ms |
17052 KB |
Output is correct |
65 |
Correct |
6 ms |
16964 KB |
Output is correct |
66 |
Correct |
5 ms |
16988 KB |
Output is correct |
67 |
Correct |
6 ms |
16988 KB |
Output is correct |
68 |
Correct |
6 ms |
17056 KB |
Output is correct |
69 |
Correct |
5 ms |
17056 KB |
Output is correct |
70 |
Correct |
6 ms |
16988 KB |
Output is correct |
71 |
Correct |
5 ms |
16988 KB |
Output is correct |
72 |
Correct |
6 ms |
16988 KB |
Output is correct |
73 |
Correct |
12 ms |
17056 KB |
Output is correct |
74 |
Correct |
5 ms |
16984 KB |
Output is correct |
75 |
Correct |
6 ms |
16988 KB |
Output is correct |
76 |
Correct |
768 ms |
17864 KB |
Output is correct |
77 |
Correct |
822 ms |
18004 KB |
Output is correct |
78 |
Correct |
817 ms |
17852 KB |
Output is correct |
79 |
Correct |
785 ms |
18120 KB |
Output is correct |
80 |
Correct |
794 ms |
18004 KB |
Output is correct |
81 |
Correct |
739 ms |
17848 KB |
Output is correct |
82 |
Correct |
771 ms |
17852 KB |
Output is correct |
83 |
Correct |
9 ms |
16988 KB |
Output is correct |
84 |
Correct |
6 ms |
16988 KB |
Output is correct |
85 |
Correct |
6 ms |
16988 KB |
Output is correct |
86 |
Correct |
6 ms |
16988 KB |
Output is correct |
87 |
Correct |
7 ms |
16988 KB |
Output is correct |
88 |
Correct |
6 ms |
16988 KB |
Output is correct |
89 |
Correct |
6 ms |
17056 KB |
Output is correct |
90 |
Correct |
6 ms |
16988 KB |
Output is correct |
91 |
Correct |
6 ms |
16988 KB |
Output is correct |
92 |
Correct |
6 ms |
16984 KB |
Output is correct |
93 |
Correct |
6 ms |
16988 KB |
Output is correct |
94 |
Correct |
6 ms |
16988 KB |
Output is correct |
95 |
Correct |
7 ms |
16988 KB |
Output is correct |
96 |
Correct |
6 ms |
16988 KB |
Output is correct |
97 |
Correct |
6 ms |
16988 KB |
Output is correct |
98 |
Correct |
6 ms |
16848 KB |
Output is correct |
99 |
Correct |
6 ms |
16988 KB |
Output is correct |
100 |
Correct |
6 ms |
16988 KB |
Output is correct |
101 |
Correct |
13 ms |
16988 KB |
Output is correct |
102 |
Correct |
6 ms |
16984 KB |
Output is correct |
103 |
Correct |
892 ms |
17952 KB |
Output is correct |
104 |
Correct |
837 ms |
18004 KB |
Output is correct |
105 |
Correct |
850 ms |
18004 KB |
Output is correct |
106 |
Correct |
812 ms |
18208 KB |
Output is correct |
107 |
Correct |
816 ms |
17848 KB |
Output is correct |
108 |
Correct |
825 ms |
17868 KB |
Output is correct |
109 |
Correct |
869 ms |
18256 KB |
Output is correct |
110 |
Correct |
5 ms |
16988 KB |
Output is correct |
111 |
Correct |
6 ms |
16988 KB |
Output is correct |
112 |
Correct |
6 ms |
17056 KB |
Output is correct |
113 |
Correct |
6 ms |
16984 KB |
Output is correct |
114 |
Correct |
6 ms |
16984 KB |
Output is correct |
115 |
Correct |
1008 ms |
18208 KB |
Output is correct |
116 |
Correct |
485 ms |
17492 KB |
Output is correct |
117 |
Correct |
519 ms |
17236 KB |
Output is correct |
118 |
Correct |
522 ms |
17232 KB |
Output is correct |
119 |
Correct |
1043 ms |
18000 KB |
Output is correct |
120 |
Correct |
1264 ms |
18000 KB |
Output is correct |
121 |
Correct |
1259 ms |
17956 KB |
Output is correct |
122 |
Correct |
1157 ms |
18212 KB |
Output is correct |
123 |
Correct |
1305 ms |
18000 KB |
Output is correct |
124 |
Correct |
1214 ms |
18000 KB |
Output is correct |
125 |
Correct |
1223 ms |
18256 KB |
Output is correct |
126 |
Correct |
8 ms |
16984 KB |
Output is correct |
127 |
Correct |
7 ms |
16988 KB |
Output is correct |
128 |
Correct |
6 ms |
16988 KB |
Output is correct |
129 |
Correct |
6 ms |
16988 KB |
Output is correct |
130 |
Correct |
6 ms |
16988 KB |
Output is correct |
131 |
Correct |
26 ms |
16988 KB |
Output is correct |
132 |
Execution timed out |
4066 ms |
17336 KB |
Time limit exceeded |
133 |
Halted |
0 ms |
0 KB |
- |