#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
#define AquA cin.tie(0);ios_base::sync_with_stdio(0);
#define fs first
#define sc second
#define p_q priority_queue
#define int long long
using namespace std;
typedef pair<int,int> pii;
int ccs=-3;
inline void srt(pair<pii,pii>& a,pii b){
if(a.fs<b){
if(a.fs.sc==b.sc){
a.sc={0,ccs};
ccs--;
}
else{
a.sc=a.fs;
}
a.fs=b;
}
else{
if(a.sc<b && a.fs.sc!=b.sc){
a.sc=b;
}
}
}
inline void srt2(pair<pii,pii>& a,pair<pii,pii> b){
srt(a,b.fs);
srt(a,b.sc);
}
inline int get(int a,int b){
return (a>>b)&1;
}
signed main(){
AquA;
int n,m;
cin >> n >> m;
int bx=1<<m;
vector<int> v(n);
vector<pair<pii,pii> > dp(bx,{{0,-1},{0,-2}});
vector<int> cnt(m);
for(int i=0;i<n;i++){
for(int j=0;j<m;j++){
int a;
cin >> a;
if(a){
cnt[j]++;
v[i]|=(1<<j);
}
}
int r=v[i]^(bx-1);
int z=__builtin_popcount(r);
srt(dp[r],{z,i});
}
for(int j=0;j<m;j++){
for(int i=bx-1;i>=0;i--){
if(!get(i,j)){
srt2(dp[i],dp[i^(1<<j)]);
}
}
}
for(int i=0;i<bx;i++){
if(dp[i].fs.sc>=0){
dp[i].fs.fs=__builtin_popcount(i);
}
if(dp[i].sc.sc>=0){
dp[i].sc.fs=__builtin_popcount(i);
}
}
for(int j=0;j<m;j++){
for(int i=0;i<bx;i++){
if(get(i,j)){
srt2(dp[i],dp[i^(1<<j)]);
}
}
}
for(int i=0;i<n;i++){
int ans=0,nw=0;
for(int j=0;j<m;j++){
if(get(v[i],j)){
cnt[j]--;
}
if(cnt[j]>=n/2 && cnt[j]-1<n/2){
nw|=(1<<j);
}
else{
if(cnt[j]>=n/2){
ans++;
}
}
}
if(dp[nw].fs.sc!=i){
cout << ans+dp[nw].fs.fs << '\n';
}
else{
cout << ans+dp[nw].sc.fs << '\n';
}
for(int j=0;j<m;j++){
if(get(v[i],j)){
cnt[j]++;
}
}
}
return 0;
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 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 |
324 KB |
Output is correct |
5 |
Correct |
146 ms |
33152 KB |
Output is correct |
6 |
Correct |
152 ms |
33108 KB |
Output is correct |
7 |
Correct |
162 ms |
33092 KB |
Output is correct |
8 |
Correct |
181 ms |
33100 KB |
Output is correct |
9 |
Correct |
195 ms |
33108 KB |
Output is correct |
10 |
Correct |
159 ms |
33088 KB |
Output is correct |
11 |
Correct |
165 ms |
33140 KB |
Output is correct |
12 |
Correct |
218 ms |
33108 KB |
Output is correct |
13 |
Correct |
0 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
320 KB |
Output is correct |
15 |
Correct |
0 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
420 KB |
Output is correct |
18 |
Correct |
0 ms |
212 KB |
Output is correct |
19 |
Correct |
0 ms |
212 KB |
Output is correct |
20 |
Correct |
0 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
0 ms |
340 KB |
Output is correct |
23 |
Correct |
0 ms |
212 KB |
Output is correct |
24 |
Correct |
0 ms |
320 KB |
Output is correct |
25 |
Correct |
0 ms |
320 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
0 ms |
212 KB |
Output is correct |
28 |
Correct |
0 ms |
316 KB |
Output is correct |
29 |
Correct |
0 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
340 KB |
Output is correct |
31 |
Correct |
1 ms |
328 KB |
Output is correct |
32 |
Correct |
0 ms |
212 KB |
Output is correct |
33 |
Correct |
0 ms |
320 KB |
Output is correct |
34 |
Correct |
0 ms |
212 KB |
Output is correct |
35 |
Correct |
0 ms |
212 KB |
Output is correct |
36 |
Correct |
0 ms |
212 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
0 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 |
1 ms |
724 KB |
Output is correct |
42 |
Correct |
2 ms |
724 KB |
Output is correct |
43 |
Correct |
2 ms |
724 KB |
Output is correct |
44 |
Correct |
2 ms |
724 KB |
Output is correct |
45 |
Correct |
2 ms |
724 KB |
Output is correct |
46 |
Correct |
10 ms |
4412 KB |
Output is correct |
47 |
Correct |
11 ms |
4436 KB |
Output is correct |
48 |
Correct |
13 ms |
4436 KB |
Output is correct |
49 |
Correct |
11 ms |
4308 KB |
Output is correct |
50 |
Correct |
13 ms |
4436 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 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 |
324 KB |
Output is correct |
5 |
Correct |
146 ms |
33152 KB |
Output is correct |
6 |
Correct |
152 ms |
33108 KB |
Output is correct |
7 |
Correct |
162 ms |
33092 KB |
Output is correct |
8 |
Correct |
181 ms |
33100 KB |
Output is correct |
9 |
Correct |
195 ms |
33108 KB |
Output is correct |
10 |
Correct |
159 ms |
33088 KB |
Output is correct |
11 |
Correct |
165 ms |
33140 KB |
Output is correct |
12 |
Correct |
218 ms |
33108 KB |
Output is correct |
13 |
Correct |
0 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
320 KB |
Output is correct |
15 |
Correct |
0 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
420 KB |
Output is correct |
18 |
Correct |
0 ms |
212 KB |
Output is correct |
19 |
Correct |
0 ms |
212 KB |
Output is correct |
20 |
Correct |
0 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
0 ms |
340 KB |
Output is correct |
23 |
Correct |
0 ms |
212 KB |
Output is correct |
24 |
Correct |
0 ms |
320 KB |
Output is correct |
25 |
Correct |
0 ms |
320 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
0 ms |
212 KB |
Output is correct |
28 |
Correct |
0 ms |
316 KB |
Output is correct |
29 |
Correct |
0 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
340 KB |
Output is correct |
31 |
Correct |
1 ms |
328 KB |
Output is correct |
32 |
Correct |
0 ms |
212 KB |
Output is correct |
33 |
Correct |
0 ms |
320 KB |
Output is correct |
34 |
Correct |
0 ms |
212 KB |
Output is correct |
35 |
Correct |
0 ms |
212 KB |
Output is correct |
36 |
Correct |
0 ms |
212 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
0 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 |
1 ms |
724 KB |
Output is correct |
42 |
Correct |
2 ms |
724 KB |
Output is correct |
43 |
Correct |
2 ms |
724 KB |
Output is correct |
44 |
Correct |
2 ms |
724 KB |
Output is correct |
45 |
Correct |
2 ms |
724 KB |
Output is correct |
46 |
Correct |
10 ms |
4412 KB |
Output is correct |
47 |
Correct |
11 ms |
4436 KB |
Output is correct |
48 |
Correct |
13 ms |
4436 KB |
Output is correct |
49 |
Correct |
11 ms |
4308 KB |
Output is correct |
50 |
Correct |
13 ms |
4436 KB |
Output is correct |
51 |
Correct |
149 ms |
33292 KB |
Output is correct |
52 |
Correct |
145 ms |
33292 KB |
Output is correct |
53 |
Correct |
177 ms |
33292 KB |
Output is correct |
54 |
Correct |
191 ms |
33296 KB |
Output is correct |
55 |
Correct |
1 ms |
340 KB |
Output is correct |
56 |
Correct |
26 ms |
4556 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
42 ms |
4312 KB |
Output is correct |
3 |
Correct |
43 ms |
4428 KB |
Output is correct |
4 |
Correct |
33 ms |
3792 KB |
Output is correct |
5 |
Correct |
48 ms |
4420 KB |
Output is correct |
6 |
Correct |
33 ms |
3788 KB |
Output is correct |
7 |
Correct |
49 ms |
4428 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
300 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
0 ms |
212 KB |
Output is correct |
13 |
Correct |
0 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
212 KB |
Output is correct |
15 |
Correct |
0 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
340 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
42 ms |
4312 KB |
Output is correct |
3 |
Correct |
43 ms |
4428 KB |
Output is correct |
4 |
Correct |
33 ms |
3792 KB |
Output is correct |
5 |
Correct |
48 ms |
4420 KB |
Output is correct |
6 |
Correct |
33 ms |
3788 KB |
Output is correct |
7 |
Correct |
49 ms |
4428 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
300 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
0 ms |
212 KB |
Output is correct |
13 |
Correct |
0 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
212 KB |
Output is correct |
15 |
Correct |
0 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 |
0 ms |
212 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
177 ms |
9084 KB |
Output is correct |
21 |
Correct |
164 ms |
8644 KB |
Output is correct |
22 |
Correct |
155 ms |
8564 KB |
Output is correct |
23 |
Correct |
141 ms |
9420 KB |
Output is correct |
24 |
Correct |
140 ms |
9156 KB |
Output is correct |
25 |
Correct |
179 ms |
9084 KB |
Output is correct |
26 |
Correct |
175 ms |
9088 KB |
Output is correct |
27 |
Correct |
0 ms |
340 KB |
Output is correct |
28 |
Correct |
0 ms |
212 KB |
Output is correct |
29 |
Correct |
0 ms |
320 KB |
Output is correct |
30 |
Correct |
1 ms |
212 KB |
Output is correct |
31 |
Correct |
1 ms |
212 KB |
Output is correct |
32 |
Correct |
1 ms |
212 KB |
Output is correct |
33 |
Correct |
0 ms |
212 KB |
Output is correct |
34 |
Correct |
0 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
1 ms |
324 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
0 ms |
212 KB |
Output is correct |
39 |
Correct |
1 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
212 KB |
Output is correct |
41 |
Correct |
0 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
212 KB |
Output is correct |
43 |
Correct |
0 ms |
212 KB |
Output is correct |
44 |
Correct |
1 ms |
340 KB |
Output is correct |
45 |
Correct |
1 ms |
320 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
42 ms |
4312 KB |
Output is correct |
3 |
Correct |
43 ms |
4428 KB |
Output is correct |
4 |
Correct |
33 ms |
3792 KB |
Output is correct |
5 |
Correct |
48 ms |
4420 KB |
Output is correct |
6 |
Correct |
33 ms |
3788 KB |
Output is correct |
7 |
Correct |
49 ms |
4428 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
300 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
0 ms |
212 KB |
Output is correct |
13 |
Correct |
0 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
212 KB |
Output is correct |
15 |
Correct |
0 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 |
0 ms |
212 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
177 ms |
9084 KB |
Output is correct |
21 |
Correct |
164 ms |
8644 KB |
Output is correct |
22 |
Correct |
155 ms |
8564 KB |
Output is correct |
23 |
Correct |
141 ms |
9420 KB |
Output is correct |
24 |
Correct |
140 ms |
9156 KB |
Output is correct |
25 |
Correct |
179 ms |
9084 KB |
Output is correct |
26 |
Correct |
175 ms |
9088 KB |
Output is correct |
27 |
Correct |
0 ms |
340 KB |
Output is correct |
28 |
Correct |
0 ms |
212 KB |
Output is correct |
29 |
Correct |
0 ms |
320 KB |
Output is correct |
30 |
Correct |
1 ms |
212 KB |
Output is correct |
31 |
Correct |
1 ms |
212 KB |
Output is correct |
32 |
Correct |
1 ms |
212 KB |
Output is correct |
33 |
Correct |
0 ms |
212 KB |
Output is correct |
34 |
Correct |
0 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
1 ms |
324 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
0 ms |
212 KB |
Output is correct |
39 |
Correct |
1 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
212 KB |
Output is correct |
41 |
Correct |
0 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
212 KB |
Output is correct |
43 |
Correct |
0 ms |
212 KB |
Output is correct |
44 |
Correct |
1 ms |
340 KB |
Output is correct |
45 |
Correct |
1 ms |
320 KB |
Output is correct |
46 |
Correct |
1 ms |
448 KB |
Output is correct |
47 |
Correct |
234 ms |
11884 KB |
Output is correct |
48 |
Correct |
215 ms |
11100 KB |
Output is correct |
49 |
Correct |
229 ms |
11100 KB |
Output is correct |
50 |
Correct |
192 ms |
12264 KB |
Output is correct |
51 |
Correct |
175 ms |
12000 KB |
Output is correct |
52 |
Correct |
242 ms |
11984 KB |
Output is correct |
53 |
Correct |
252 ms |
12264 KB |
Output is correct |
54 |
Correct |
2 ms |
832 KB |
Output is correct |
55 |
Correct |
2 ms |
724 KB |
Output is correct |
56 |
Correct |
2 ms |
724 KB |
Output is correct |
57 |
Correct |
2 ms |
724 KB |
Output is correct |
58 |
Correct |
2 ms |
832 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
1 ms |
212 KB |
Output is correct |
2 |
Correct |
42 ms |
4312 KB |
Output is correct |
3 |
Correct |
43 ms |
4428 KB |
Output is correct |
4 |
Correct |
33 ms |
3792 KB |
Output is correct |
5 |
Correct |
48 ms |
4420 KB |
Output is correct |
6 |
Correct |
33 ms |
3788 KB |
Output is correct |
7 |
Correct |
49 ms |
4428 KB |
Output is correct |
8 |
Correct |
1 ms |
212 KB |
Output is correct |
9 |
Correct |
1 ms |
212 KB |
Output is correct |
10 |
Correct |
1 ms |
300 KB |
Output is correct |
11 |
Correct |
1 ms |
212 KB |
Output is correct |
12 |
Correct |
0 ms |
212 KB |
Output is correct |
13 |
Correct |
0 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
212 KB |
Output is correct |
15 |
Correct |
0 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 |
0 ms |
212 KB |
Output is correct |
19 |
Correct |
1 ms |
212 KB |
Output is correct |
20 |
Correct |
177 ms |
9084 KB |
Output is correct |
21 |
Correct |
164 ms |
8644 KB |
Output is correct |
22 |
Correct |
155 ms |
8564 KB |
Output is correct |
23 |
Correct |
141 ms |
9420 KB |
Output is correct |
24 |
Correct |
140 ms |
9156 KB |
Output is correct |
25 |
Correct |
179 ms |
9084 KB |
Output is correct |
26 |
Correct |
175 ms |
9088 KB |
Output is correct |
27 |
Correct |
0 ms |
340 KB |
Output is correct |
28 |
Correct |
0 ms |
212 KB |
Output is correct |
29 |
Correct |
0 ms |
320 KB |
Output is correct |
30 |
Correct |
1 ms |
212 KB |
Output is correct |
31 |
Correct |
1 ms |
212 KB |
Output is correct |
32 |
Correct |
1 ms |
212 KB |
Output is correct |
33 |
Correct |
0 ms |
212 KB |
Output is correct |
34 |
Correct |
0 ms |
212 KB |
Output is correct |
35 |
Correct |
1 ms |
340 KB |
Output is correct |
36 |
Correct |
1 ms |
324 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
0 ms |
212 KB |
Output is correct |
39 |
Correct |
1 ms |
212 KB |
Output is correct |
40 |
Correct |
1 ms |
212 KB |
Output is correct |
41 |
Correct |
0 ms |
212 KB |
Output is correct |
42 |
Correct |
1 ms |
212 KB |
Output is correct |
43 |
Correct |
0 ms |
212 KB |
Output is correct |
44 |
Correct |
1 ms |
340 KB |
Output is correct |
45 |
Correct |
1 ms |
320 KB |
Output is correct |
46 |
Correct |
1 ms |
448 KB |
Output is correct |
47 |
Correct |
234 ms |
11884 KB |
Output is correct |
48 |
Correct |
215 ms |
11100 KB |
Output is correct |
49 |
Correct |
229 ms |
11100 KB |
Output is correct |
50 |
Correct |
192 ms |
12264 KB |
Output is correct |
51 |
Correct |
175 ms |
12000 KB |
Output is correct |
52 |
Correct |
242 ms |
11984 KB |
Output is correct |
53 |
Correct |
252 ms |
12264 KB |
Output is correct |
54 |
Correct |
2 ms |
832 KB |
Output is correct |
55 |
Correct |
2 ms |
724 KB |
Output is correct |
56 |
Correct |
2 ms |
724 KB |
Output is correct |
57 |
Correct |
2 ms |
724 KB |
Output is correct |
58 |
Correct |
2 ms |
832 KB |
Output is correct |
59 |
Correct |
274 ms |
14944 KB |
Output is correct |
60 |
Correct |
146 ms |
9412 KB |
Output is correct |
61 |
Correct |
132 ms |
9724 KB |
Output is correct |
62 |
Correct |
147 ms |
9920 KB |
Output is correct |
63 |
Correct |
280 ms |
14696 KB |
Output is correct |
64 |
Correct |
293 ms |
17356 KB |
Output is correct |
65 |
Correct |
307 ms |
17264 KB |
Output is correct |
66 |
Correct |
244 ms |
17648 KB |
Output is correct |
67 |
Correct |
223 ms |
17256 KB |
Output is correct |
68 |
Correct |
302 ms |
17296 KB |
Output is correct |
69 |
Correct |
327 ms |
17604 KB |
Output is correct |
70 |
Correct |
10 ms |
4420 KB |
Output is correct |
71 |
Correct |
10 ms |
4308 KB |
Output is correct |
72 |
Correct |
12 ms |
4436 KB |
Output is correct |
73 |
Correct |
11 ms |
4308 KB |
Output is correct |
74 |
Correct |
12 ms |
4308 KB |
Output is correct |
75 |
Correct |
21 ms |
4568 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 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 |
324 KB |
Output is correct |
5 |
Correct |
146 ms |
33152 KB |
Output is correct |
6 |
Correct |
152 ms |
33108 KB |
Output is correct |
7 |
Correct |
162 ms |
33092 KB |
Output is correct |
8 |
Correct |
181 ms |
33100 KB |
Output is correct |
9 |
Correct |
195 ms |
33108 KB |
Output is correct |
10 |
Correct |
159 ms |
33088 KB |
Output is correct |
11 |
Correct |
165 ms |
33140 KB |
Output is correct |
12 |
Correct |
218 ms |
33108 KB |
Output is correct |
13 |
Correct |
0 ms |
212 KB |
Output is correct |
14 |
Correct |
0 ms |
320 KB |
Output is correct |
15 |
Correct |
0 ms |
212 KB |
Output is correct |
16 |
Correct |
0 ms |
212 KB |
Output is correct |
17 |
Correct |
1 ms |
420 KB |
Output is correct |
18 |
Correct |
0 ms |
212 KB |
Output is correct |
19 |
Correct |
0 ms |
212 KB |
Output is correct |
20 |
Correct |
0 ms |
212 KB |
Output is correct |
21 |
Correct |
1 ms |
212 KB |
Output is correct |
22 |
Correct |
0 ms |
340 KB |
Output is correct |
23 |
Correct |
0 ms |
212 KB |
Output is correct |
24 |
Correct |
0 ms |
320 KB |
Output is correct |
25 |
Correct |
0 ms |
320 KB |
Output is correct |
26 |
Correct |
1 ms |
212 KB |
Output is correct |
27 |
Correct |
0 ms |
212 KB |
Output is correct |
28 |
Correct |
0 ms |
316 KB |
Output is correct |
29 |
Correct |
0 ms |
212 KB |
Output is correct |
30 |
Correct |
1 ms |
340 KB |
Output is correct |
31 |
Correct |
1 ms |
328 KB |
Output is correct |
32 |
Correct |
0 ms |
212 KB |
Output is correct |
33 |
Correct |
0 ms |
320 KB |
Output is correct |
34 |
Correct |
0 ms |
212 KB |
Output is correct |
35 |
Correct |
0 ms |
212 KB |
Output is correct |
36 |
Correct |
0 ms |
212 KB |
Output is correct |
37 |
Correct |
1 ms |
212 KB |
Output is correct |
38 |
Correct |
0 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 |
1 ms |
724 KB |
Output is correct |
42 |
Correct |
2 ms |
724 KB |
Output is correct |
43 |
Correct |
2 ms |
724 KB |
Output is correct |
44 |
Correct |
2 ms |
724 KB |
Output is correct |
45 |
Correct |
2 ms |
724 KB |
Output is correct |
46 |
Correct |
10 ms |
4412 KB |
Output is correct |
47 |
Correct |
11 ms |
4436 KB |
Output is correct |
48 |
Correct |
13 ms |
4436 KB |
Output is correct |
49 |
Correct |
11 ms |
4308 KB |
Output is correct |
50 |
Correct |
13 ms |
4436 KB |
Output is correct |
51 |
Correct |
149 ms |
33292 KB |
Output is correct |
52 |
Correct |
145 ms |
33292 KB |
Output is correct |
53 |
Correct |
177 ms |
33292 KB |
Output is correct |
54 |
Correct |
191 ms |
33296 KB |
Output is correct |
55 |
Correct |
1 ms |
340 KB |
Output is correct |
56 |
Correct |
26 ms |
4556 KB |
Output is correct |
57 |
Correct |
1 ms |
212 KB |
Output is correct |
58 |
Correct |
42 ms |
4312 KB |
Output is correct |
59 |
Correct |
43 ms |
4428 KB |
Output is correct |
60 |
Correct |
33 ms |
3792 KB |
Output is correct |
61 |
Correct |
48 ms |
4420 KB |
Output is correct |
62 |
Correct |
33 ms |
3788 KB |
Output is correct |
63 |
Correct |
49 ms |
4428 KB |
Output is correct |
64 |
Correct |
1 ms |
212 KB |
Output is correct |
65 |
Correct |
1 ms |
212 KB |
Output is correct |
66 |
Correct |
1 ms |
300 KB |
Output is correct |
67 |
Correct |
1 ms |
212 KB |
Output is correct |
68 |
Correct |
0 ms |
212 KB |
Output is correct |
69 |
Correct |
0 ms |
212 KB |
Output is correct |
70 |
Correct |
0 ms |
212 KB |
Output is correct |
71 |
Correct |
0 ms |
212 KB |
Output is correct |
72 |
Correct |
0 ms |
212 KB |
Output is correct |
73 |
Correct |
1 ms |
340 KB |
Output is correct |
74 |
Correct |
0 ms |
212 KB |
Output is correct |
75 |
Correct |
1 ms |
212 KB |
Output is correct |
76 |
Correct |
177 ms |
9084 KB |
Output is correct |
77 |
Correct |
164 ms |
8644 KB |
Output is correct |
78 |
Correct |
155 ms |
8564 KB |
Output is correct |
79 |
Correct |
141 ms |
9420 KB |
Output is correct |
80 |
Correct |
140 ms |
9156 KB |
Output is correct |
81 |
Correct |
179 ms |
9084 KB |
Output is correct |
82 |
Correct |
175 ms |
9088 KB |
Output is correct |
83 |
Correct |
0 ms |
340 KB |
Output is correct |
84 |
Correct |
0 ms |
212 KB |
Output is correct |
85 |
Correct |
0 ms |
320 KB |
Output is correct |
86 |
Correct |
1 ms |
212 KB |
Output is correct |
87 |
Correct |
1 ms |
212 KB |
Output is correct |
88 |
Correct |
1 ms |
212 KB |
Output is correct |
89 |
Correct |
0 ms |
212 KB |
Output is correct |
90 |
Correct |
0 ms |
212 KB |
Output is correct |
91 |
Correct |
1 ms |
340 KB |
Output is correct |
92 |
Correct |
1 ms |
324 KB |
Output is correct |
93 |
Correct |
1 ms |
212 KB |
Output is correct |
94 |
Correct |
0 ms |
212 KB |
Output is correct |
95 |
Correct |
1 ms |
212 KB |
Output is correct |
96 |
Correct |
1 ms |
212 KB |
Output is correct |
97 |
Correct |
0 ms |
212 KB |
Output is correct |
98 |
Correct |
1 ms |
212 KB |
Output is correct |
99 |
Correct |
0 ms |
212 KB |
Output is correct |
100 |
Correct |
1 ms |
340 KB |
Output is correct |
101 |
Correct |
1 ms |
320 KB |
Output is correct |
102 |
Correct |
1 ms |
448 KB |
Output is correct |
103 |
Correct |
234 ms |
11884 KB |
Output is correct |
104 |
Correct |
215 ms |
11100 KB |
Output is correct |
105 |
Correct |
229 ms |
11100 KB |
Output is correct |
106 |
Correct |
192 ms |
12264 KB |
Output is correct |
107 |
Correct |
175 ms |
12000 KB |
Output is correct |
108 |
Correct |
242 ms |
11984 KB |
Output is correct |
109 |
Correct |
252 ms |
12264 KB |
Output is correct |
110 |
Correct |
2 ms |
832 KB |
Output is correct |
111 |
Correct |
2 ms |
724 KB |
Output is correct |
112 |
Correct |
2 ms |
724 KB |
Output is correct |
113 |
Correct |
2 ms |
724 KB |
Output is correct |
114 |
Correct |
2 ms |
832 KB |
Output is correct |
115 |
Correct |
274 ms |
14944 KB |
Output is correct |
116 |
Correct |
146 ms |
9412 KB |
Output is correct |
117 |
Correct |
132 ms |
9724 KB |
Output is correct |
118 |
Correct |
147 ms |
9920 KB |
Output is correct |
119 |
Correct |
280 ms |
14696 KB |
Output is correct |
120 |
Correct |
293 ms |
17356 KB |
Output is correct |
121 |
Correct |
307 ms |
17264 KB |
Output is correct |
122 |
Correct |
244 ms |
17648 KB |
Output is correct |
123 |
Correct |
223 ms |
17256 KB |
Output is correct |
124 |
Correct |
302 ms |
17296 KB |
Output is correct |
125 |
Correct |
327 ms |
17604 KB |
Output is correct |
126 |
Correct |
10 ms |
4420 KB |
Output is correct |
127 |
Correct |
10 ms |
4308 KB |
Output is correct |
128 |
Correct |
12 ms |
4436 KB |
Output is correct |
129 |
Correct |
11 ms |
4308 KB |
Output is correct |
130 |
Correct |
12 ms |
4308 KB |
Output is correct |
131 |
Correct |
21 ms |
4568 KB |
Output is correct |
132 |
Correct |
548 ms |
48044 KB |
Output is correct |
133 |
Correct |
507 ms |
47908 KB |
Output is correct |
134 |
Correct |
510 ms |
48044 KB |
Output is correct |
135 |
Correct |
607 ms |
48012 KB |
Output is correct |
136 |
Correct |
587 ms |
48028 KB |
Output is correct |
137 |
Correct |
448 ms |
30928 KB |
Output is correct |
138 |
Correct |
433 ms |
31124 KB |
Output is correct |
139 |
Correct |
410 ms |
48148 KB |
Output is correct |
140 |
Correct |
387 ms |
47748 KB |
Output is correct |
141 |
Correct |
536 ms |
47816 KB |
Output is correct |
142 |
Correct |
559 ms |
48076 KB |
Output is correct |