QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#166768#2733. Rainfall Capturelmeowdn25 ✓23ms176448kbC++142.1kb2023-09-06 17:54:462023-09-06 17:54:46

Judging History

你现在查看的是最新测评结果

  • [2023-09-06 17:54:46]
  • 评测
  • 测评结果:25
  • 用时:23ms
  • 内存:176448kb
  • [2023-09-06 17:54:46]
  • 提交

answer

#include<bits/stdc++.h>
#define fi first
#define se second
#define eb emplace_back
#define mp make_pair
using namespace std;
typedef long double ld;
typedef long long ll;
typedef unsigned long long ull;
typedef __int128 i128; 
template<typename T,typename U>
T ceil(T x, U y) {return (x>0?(x+y-1)/y:x/y);}
template<typename T,typename U>
T floor(T x, U y) {return (x>0?x/y:(x-y+1)/y);}
template<class T,class S>
bool chmax(T &a,const S b) {return (a<b?a=b,1:0);}
template<class T,class S>
bool chmin(T &a,const S b) {return (a>b?a=b,1:0);}
int popcnt(int x) {return __builtin_popcount(x);}
int popcnt(ll x)  {return __builtin_popcountll(x);}
int topbit(int x) {return (x==0?-1:31-__builtin_clz(x));}
int topbit(ll x)  {return (x==0?-1:63-__builtin_clzll(x));}
int lowbit(int x) {return (x==0?-1:__builtin_ctz(x));}
int lowbit(ll x)  {return (x==0?-1:__builtin_ctzll(x));}

#define rep(i,a,b) for(int i=(a);i<=(b);i++)
#define per(i,a,b) for(int i=(a);i>=(b);i--)
typedef pair<int,int> pii; 
typedef vector<int> vi;
typedef vector<pii> vp;
typedef tuple<int,int,int> tiii;
int read() {
  int x=0,w=1; char c=getchar(); 
  while(!isdigit(c)) {if(c=='-') w=-1; c=getchar();}
  while(isdigit(c)) {x=x*10+(c-'0'); c=getchar();}
  return x*w;
}

const int N=505,M=55;
int n,m,a[N],c[N],sum;
bitset<N*M> f[M][N][2],ans;

signed main() {
  n=read();
  rep(i,1,n) a[i]=read(), chmax(m,a[i]);
  rep(i,1,n) c[a[i]]++, sum+=a[i];
  c[m]--; sum-=m;
  rep(i,1,m) c[i]+=c[i-1];
  f[0][0][1][0]=1;
  rep(i,1,m) {
    rep(j,0,c[i-1]) f[i][j][1]=f[i-1][j][1];
    if(c[i]!=c[i-1]) {
      rep(j,0,c[i-1]) f[i][j+1][0]=f[i-1][j][1]<<i;
      rep(j,1,c[i]) f[i][j][0]|=f[i][j-1][0]<<i;
      rep(j,0,c[i]) f[i][j][1]|=f[i][j][0];
      if(c[i]==c[m]) {
        rep(j,0,c[i]) ans|=f[i][j][0]<<(i*(c[i]-j));
      }
    }
    /*
    rep(j,0,c[i]) {
      cout<<i<<" "<<j<<endl;
      cout<<"A: "; rep(k,0,n*m) putchar('0'+f[i][j][1][k]); puts("");
      cout<<"I: "; rep(k,0,n*m) putchar('0'+f[i][j][0][k]); puts("");
    }
    */
  }
  ans>>=sum;
  rep(j,0,n*m) if(ans[j]) printf("%d ",j);
  puts("");
  return 0;
}

详细

Subtask #1:

score: 5
Accepted

Test #1:

score: 5
Accepted
time: 4ms
memory: 108424kb

input:

2
1 50

output:

0 

result:

ok single line: '0 '

Test #2:

score: 0
Accepted
time: 1ms
memory: 110308kb

input:

10
50 50 1 1 1 1 1 1 1 1

output:

0 49 98 147 196 245 294 343 392 

result:

ok single line: '0 49 98 147 196 245 294 343 392 '

Test #3:

score: 0
Accepted
time: 1ms
memory: 110248kb

input:

10
50 50 2 2 2 1 2 1 2 2

output:

0 1 2 48 49 50 96 97 98 144 145 146 192 193 194 240 241 242 288 289 290 337 338 386 

result:

ok single line: '0 1 2 48 49 50 96 97 98 144 14...41 242 288 289 290 337 338 386 '

Test #4:

score: 0
Accepted
time: 1ms
memory: 110476kb

input:

10
50 50 3 2 3 3 3 2 3 2

output:

0 1 2 3 47 48 49 50 94 95 96 97 141 142 143 144 188 189 190 191 235 236 237 238 283 284 285 331 332 379 

result:

ok single line: '0 1 2 3 47 48 49 50 94 95 96 9...37 238 283 284 285 331 332 379 '

Test #5:

score: 0
Accepted
time: 1ms
memory: 71404kb

input:

8
16 33 33 16 33 33 33 16

output:

0 17 34 51 

result:

ok single line: '0 17 34 51 '

Test #6:

score: 0
Accepted
time: 1ms
memory: 106412kb

input:

9
14 45 14 50 34 24 34 14 34

output:

0 10 11 20 21 22 30 31 32 33 40 41 42 43 50 51 52 53 54 60 61 62 63 64 70 71 72 73 74 81 82 83 84 85 92 93 94 95 103 104 105 114 115 116 125 126 136 147 

result:

ok single line: '0 10 11 20 21 22 30 31 32 33 4...05 114 115 116 125 126 136 147 '

Test #7:

score: 0
Accepted
time: 1ms
memory: 38632kb

input:

6
17 17 4 17 17 17

output:

0 13 

result:

ok single line: '0 13 '

Test #8:

score: 0
Accepted
time: 1ms
memory: 106184kb

input:

7
36 50 50 40 43 50 40

output:

0 3 4 6 7 10 11 13 14 17 20 21 24 27 31 34 41 

result:

ok single line: '0 3 4 6 7 10 11 13 14 17 20 21 24 27 31 34 41 '

Test #9:

score: 0
Accepted
time: 0ms
memory: 79780kb

input:

8
37 10 10 37 37 10 10 37

output:

0 27 54 81 108 

result:

ok single line: '0 27 54 81 108 '

Test #10:

score: 0
Accepted
time: 1ms
memory: 52884kb

input:

7
24 17 4 24 4 4 24

output:

0 7 13 20 26 27 33 39 40 46 47 53 60 67 

result:

ok single line: '0 7 13 20 26 27 33 39 40 46 47 53 60 67 '

Test #11:

score: 0
Accepted
time: 1ms
memory: 108268kb

input:

8
21 21 17 18 47 47 18 50

output:

0 1 3 4 6 7 10 26 27 29 30 32 33 36 52 53 55 56 58 59 62 81 82 84 85 88 110 111 114 140 

result:

ok single line: '0 1 3 4 6 7 10 26 27 29 30 32 ...81 82 84 85 88 110 111 114 140 '

Test #12:

score: 0
Accepted
time: 0ms
memory: 52904kb

input:

7
9 9 23 9 23 9 9

output:

0 14 28 42 56 70 

result:

ok single line: '0 14 28 42 56 70 '

Test #13:

score: 0
Accepted
time: 1ms
memory: 104168kb

input:

8
49 7 7 49 7 49 7 7

output:

0 42 84 126 168 210 

result:

ok single line: '0 42 84 126 168 210 '

Test #14:

score: 0
Accepted
time: 1ms
memory: 87700kb

input:

10
18 35 41 41 18 3 35 18 18 3

output:

0 6 12 15 17 21 23 27 29 30 32 34 35 36 38 40 42 44 46 47 49 50 51 52 53 55 57 58 59 61 63 64 65 66 67 68 69 70 72 73 74 75 76 78 80 81 82 83 84 86 87 88 89 90 92 93 95 96 98 99 100 101 104 105 106 107 110 111 112 113 115 116 118 119 121 122 124 127 128 130 132 133 134 136 138 139 142 144 145 150 15...

result:

ok single line: '0 6 12 15 17 21 23 27 29 30 32...50 151 156 157 162 168 174 180 '

Test #15:

score: 0
Accepted
time: 1ms
memory: 100012kb

input:

9
7 47 47 29 7 47 7 47 47

output:

0 18 22 40 44 58 62 66 80 84 98 102 120 138 

result:

ok single line: '0 18 22 40 44 58 62 66 80 84 98 102 120 138 '

Test #16:

score: 0
Accepted
time: 1ms
memory: 67512kb

input:

8
31 31 31 31 21 31 31 21

output:

0 10 20 

result:

ok single line: '0 10 20 '

Test #17:

score: 0
Accepted
time: 1ms
memory: 102124kb

input:

9
35 38 48 35 35 48 18 30 30

output:

0 3 5 6 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 61 62 63 64 65 66 67 69 71 72 74 75 76 77 79 82 84 85 87 89 92 95 97 102 105 115 

result:

ok single line: '0 3 5 6 8 9 10 11 12 13 14 15 ... 85 87 89 92 95 97 102 105 115 '

Test #18:

score: 0
Accepted
time: 1ms
memory: 92080kb

input:

4
43 43 43 39

output:

0 4 

result:

ok single line: '0 4 '

Test #19:

score: 0
Accepted
time: 1ms
memory: 102316kb

input:

7
15 28 8 46 40 8 28

output:

0 7 12 13 14 19 20 24 25 26 27 31 32 33 37 38 39 40 44 45 49 51 52 53 56 57 63 64 65 69 76 77 81 88 89 101 113 

result:

ok single line: '0 7 12 13 14 19 20 24 25 26 27...4 65 69 76 77 81 88 89 101 113 '

Test #20:

score: 0
Accepted
time: 1ms
memory: 81640kb

input:

6
37 3 3 22 35 3

output:

0 13 19 32 38 45 51 57 64 70 77 83 96 109 

result:

ok single line: '0 13 19 32 38 45 51 57 64 70 77 83 96 109 '

Subtask #2:

score: 10
Accepted

Dependency #1:

100%
Accepted

Test #21:

score: 10
Accepted
time: 1ms
memory: 124540kb

input:

50
50 50 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1

output:

0 49 98 147 196 245 294 343 392 441 490 539 588 637 686 735 784 833 882 931 980 1029 1078 1127 1176 1225 1274 1323 1372 1421 1470 1519 1568 1617 1666 1715 1764 1813 1862 1911 1960 2009 2058 2107 2156 2205 2254 2303 2352 

result:

ok single line: '0 49 98 147 196 245 294 343 39... 2107 2156 2205 2254 2303 2352 '

Test #22:

score: 0
Accepted
time: 1ms
memory: 124632kb

input:

50
50 50 1 2 1 1 1 1 2 2 1 1 1 1 2 2 2 2 2 1 1 1 2 1 1 1 2 1 2 2 2 1 2 1 1 2 2 1 1 1 2 2 2 1 2 1 1 2 1 2

output:

0 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 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 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 144 145 146 147 148 149 150 151 152 153 154 ...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 2232 2233 2234 2281 2282 2330 '

Test #23:

score: 0
Accepted
time: 1ms
memory: 122796kb

input:

50
50 50 2 3 1 1 2 2 3 3 2 3 3 3 3 1 2 3 2 1 2 3 3 1 2 3 3 3 2 2 1 1 1 2 1 3 1 2 1 1 2 2 3 3 1 3 1 3 1 3

output:

0 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 41 42 43 44 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 94 95 96 97 98 99 100 101 102 103 104 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 2205 2206 2251 2252 2253 2300 '

Test #24:

score: 0
Accepted
time: 4ms
memory: 20328kb

input:

50
8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8 8

output:

0 

result:

ok single line: '0 '

Test #25:

score: 0
Accepted
time: 1ms
memory: 57260kb

input:

50
22 22 26 26 26 26 26 22 26 26 22 26 26 22 22 26 26 22 26 26 26 22 22 22 26 22 26 26 22 22 22 26 22 26 22 26 26 22 26 26 22 22 22 22 26 26 22 26 22 22

output:

0 4 8 12 16 20 24 28 32 36 40 44 48 52 56 60 64 68 72 76 80 84 88 92 96 

result:

ok single line: '0 4 8 12 16 20 24 28 32 36 40 ... 60 64 68 72 76 80 84 88 92 96 '

Test #26:

score: 0
Accepted
time: 4ms
memory: 104160kb

input:

50
2 29 7 8 8 18 21 42 8 38 22 46 26 28 42 28 38 28 7 26 29 28 22 18 7 2 8 45 28 42 2 3 21 21 2 29 18 2 28 3 28 37 18 20 39 37 31 2 8 38

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 1154 1155 1156 1157 1160 1163 '

Test #27:

score: 0
Accepted
time: 1ms
memory: 114396kb

input:

50
50 50 18 35 30 3 37 3 24 5 5 3 21 8 31 7 3 3 3 30 28 34 50 34 35 50 12 32 35 32 24 16 5 5 35 28 5 16 21 18 21 34 50 32 30 32 24 34 7 16

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 1317 1318 1320 1321 1323 1336 '

Test #28:

score: 0
Accepted
time: 1ms
memory: 112524kb

input:

50
35 18 47 35 27 6 19 4 24 30 6 17 18 24 6 30 35 28 23 47 35 5 5 6 4 6 27 17 23 19 6 27 28 23 24 4 23 6 17 47 28 24 23 23 30 31 17 4 31 23

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 1265 1266 1268 1269 1273 1285 '

Test #29:

score: 0
Accepted
time: 1ms
memory: 114316kb

input:

50
46 7 42 39 48 39 5 32 29 6 5 38 12 26 11 2 45 5 44 49 44 6 22 42 26 11 48 34 7 42 9 15 5 7 21 3 41 35 22 7 2 11 48 44 49 42 33 41 15 15

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 1168 1169 1170 1171 1172 1173 '

Test #30:

score: 0
Accepted
time: 1ms
memory: 108132kb

input:

50
49 10 7 34 19 49 40 32 25 5 10 3 46 39 40 40 30 31 15 25 36 30 5 46 39 33 34 3 21 30 35 30 28 40 20 6 16 25 25 36 49 40 5 35 36 4 38 8 26 49

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 1062 1063 1064 1067 1070 1073 '

Test #31:

score: 0
Accepted
time: 1ms
memory: 77544kb

input:

38
33 33 33 28 28 28 28 36 28 28 28 28 36 33 33 28 36 33 36 33 36 33 36 28 33 28 28 33 28 36 36 36 36 33 33 28 28 28

output:

0 3 5 6 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 100 101 102 103 10...

result:

ok single line: '0 3 5 6 8 9 10 11 12 13 14 15 ...50 152 153 155 156 158 161 164 '

Test #32:

score: 0
Accepted
time: 1ms
memory: 85648kb

input:

36
38 25 25 25 39 38 39 7 7 7 23 7 7 23 39 23 23 7 23 23 25 23 39 23 38 23 25 38 23 38 25 39 39 25 23 38

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1...65 466 467 468 469 470 471 472 '

Test #33:

score: 0
Accepted
time: 1ms
memory: 116716kb

input:

41
10 28 50 42 28 35 35 10 33 42 33 28 42 42 33 33 42 42 50 33 35 10 35 33 33 28 50 28 33 50 35 42 50 42 50 35 35 28 33 10 33

output:

0 2 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 100 101 102 10...

result:

ok single line: '0 2 4 5 6 7 8 9 10 11 12 13 14...07 608 609 614 615 616 623 631 '

Test #34:

score: 0
Accepted
time: 1ms
memory: 106480kb

input:

43
45 5 45 45 5 45 5 5 13 45 13 5 45 45 45 13 5 5 5 45 13 45 5 45 45 5 5 45 13 45 45 5 45 45 13 13 45 13 5 5 5 13 5

output:

0 8 16 24 32 40 48 56 64 72 80 88 96 104 112 120 128 136 144 152 160 168 176 184 192 200 208 216 224 232 240 248 256 264 272 280 288 296 304 312 320 328 336 344 352 360 368 376 384 392 400 408 416 424 432 440 448 456 464 472 480 488 496 504 512 520 528 536 544 552 560 568 576 584 592 600 608 616 624...

result:

ok single line: '0 8 16 24 32 40 48 56 64 72 80...24 832 848 856 864 888 896 928 '

Test #35:

score: 0
Accepted
time: 0ms
memory: 99944kb

input:

31
4 42 9 4 4 9 2 2 9 2 2 9 4 9 9 42 4 2 42 42 42 2 4 2 9 2 4 2 4 4 42

output:

0 2 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 100 101 102 10...

result:

ok single line: '0 2 4 5 6 7 8 9 10 11 12 13 14...57 860 862 867 893 895 900 933 '

Test #36:

score: 0
Accepted
time: 3ms
memory: 97964kb

input:

42
33 33 6 33 6 6 43 6 43 43 43 33 43 43 43 43 6 33 43 33 33 43 33 43 43 43 6 43 43 6 6 33 33 43 43 6 43 6 33 6 43 43

output:

0 10 20 27 30 37 40 47 50 54 57 60 64 67 70 74 77 80 81 84 87 90 91 94 97 100 101 104 107 108 110 111 114 117 118 121 124 127 128 131 134 135 137 138 141 144 145 147 148 151 154 155 158 161 162 164 165 168 171 172 174 175 178 181 182 184 185 188 189 191 192 195 198 199 201 202 205 208 209 211 212 21...

result:

ok single line: '0 10 20 27 30 37 40 47 50 54 5...67 470 477 480 487 497 507 517 '

Test #37:

score: 0
Accepted
time: 1ms
memory: 102308kb

input:

34
3 1 16 39 39 3 16 16 44 39 44 39 39 3 16 3 44 1 39 16 44 16 16 16 3 16 3 3 39 3 44 3 39 44

output:

0 2 4 5 7 9 10 12 13 14 15 17 18 19 20 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 100 101 102 103 104 105 106...

result:

ok single line: '0 2 4 5 7 9 10 12 13 14 15 17 ...17 719 722 727 732 737 742 747 '

Test #38:

score: 0
Accepted
time: 1ms
memory: 100004kb

input:

31
46 46 34 34 19 32 32 46 19 46 46 46 46 32 46 32 34 34 34 46 32 32 34 34 46 19 34 34 19 46 46

output:

0 2 4 6 8 10 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 100 101 102 103 104 105...

result:

ok single line: '0 2 4 6 8 10 12 13 14 15 16 17...64 272 273 274 276 286 288 300 '

Test #39:

score: 0
Accepted
time: 0ms
memory: 87984kb

input:

50
37 3 31 37 21 18 7 7 3 31 31 18 3 31 7 37 7 31 37 3 18 7 3 18 3 31 7 3 21 7 21 18 37 3 21 18 31 37 7 3 3 7 21 7 31 3 37 21 18 3

output:

0 3 4 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 100 101 102 103 ...

result:

ok single line: '0 3 4 6 7 8 9 10 11 12 13 14 1...61 963 966 967 969 973 979 985 '

Test #40:

score: 0
Accepted
time: 4ms
memory: 89796kb

input:

33
39 39 39 28 39 11 39 11 11 11 11 39 39 11 11 28 39 39 39 11 11 28 11 11 39 11 11 28 11 39 39 11 28

output:

0 11 17 22 28 33 34 39 44 45 50 51 55 56 61 62 67 68 72 73 78 79 83 84 85 89 90 95 96 100 101 102 106 107 111 112 113 117 118 119 123 124 128 129 130 134 135 136 139 140 141 145 146 147 151 152 153 156 157 158 162 163 164 167 168 169 170 173 174 175 179 180 181 184 185 186 187 190 191 192 195 196 19...

result:

ok single line: '0 11 17 22 28 33 34 39 44 45 5...25 431 436 442 447 453 464 475 '

Subtask #3:

score: 10
Accepted

Dependency #1:

100%
Accepted

Dependency #2:

100%
Accepted

Test #41:

score: 10
Accepted
time: 3ms
memory: 175744kb

input:

500
50 50 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 ...

output:

0 49 98 147 196 245 294 343 392 441 490 539 588 637 686 735 784 833 882 931 980 1029 1078 1127 1176 1225 1274 1323 1372 1421 1470 1519 1568 1617 1666 1715 1764 1813 1862 1911 1960 2009 2058 2107 2156 2205 2254 2303 2352 2401 2450 2499 2548 2597 2646 2695 2744 2793 2842 2891 2940 2989 3038 3087 3136 ...

result:

ok single line: '0 49 98 147 196 245 294 343 39... 24206 24255 24304 24353 24402 '

Test #42:

score: 0
Accepted
time: 20ms
memory: 176448kb

input:

500
50 50 1 2 1 1 2 1 1 1 2 2 1 2 1 2 2 2 2 2 1 2 2 2 1 2 2 2 2 1 2 2 2 2 2 2 2 1 1 2 2 2 2 1 2 2 1 1 2 1 1 1 1 2 1 2 2 2 2 2 2 2 1 2 2 1 2 2 1 2 2 2 2 1 1 1 1 2 1 2 1 1 1 2 2 1 2 1 1 1 2 1 1 1 1 2 1 2 1 2 1 2 1 1 1 1 1 1 1 1 2 1 2 2 2 2 2 2 2 2 2 1 1 2 1 1 2 2 2 2 1 1 1 2 1 1 2 1 2 1 2 1 1 2 1 2 2 ...

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 24052 24053 24100 24101 24149 '

Test #43:

score: 0
Accepted
time: 23ms
memory: 175000kb

input:

500
50 50 1 2 3 3 1 3 1 3 2 2 2 2 3 2 3 1 3 2 2 3 1 2 3 1 1 1 2 1 2 3 2 3 3 1 2 2 1 3 1 2 2 2 2 1 1 2 3 1 2 3 3 2 1 2 1 1 3 2 2 2 3 1 2 1 3 2 3 3 1 2 2 3 2 3 3 1 1 3 1 3 2 2 1 2 3 2 2 2 2 3 1 1 2 1 3 1 1 3 1 1 2 2 3 1 3 1 3 3 3 2 2 1 2 3 1 1 1 3 2 2 3 2 2 1 1 3 2 2 3 2 2 2 3 3 1 3 2 3 1 1 1 3 2 3 3 ...

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 23791 23836 23837 23838 23885 '

Test #44:

score: 0
Accepted
time: 1ms
memory: 71392kb

input:

500
32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32...

output:

0 

result:

ok single line: '0 '

Test #45:

score: 0
Accepted
time: 3ms
memory: 112920kb

input:

500
42 48 42 48 42 42 42 42 48 42 42 48 48 48 42 48 48 48 42 42 42 42 48 42 42 48 42 42 42 48 42 48 42 42 42 48 48 42 42 48 48 42 48 42 42 42 42 48 48 48 48 42 42 48 42 42 48 48 42 42 42 48 48 42 42 42 42 48 42 48 48 48 42 48 42 48 48 48 48 42 42 48 42 48 42 42 42 42 42 48 48 48 42 42 42 42 42 48 48...

output:

0 6 12 18 24 30 36 42 48 54 60 66 72 78 84 90 96 102 108 114 120 126 132 138 144 150 156 162 168 174 180 186 192 198 204 210 216 222 228 234 240 246 252 258 264 270 276 282 288 294 300 306 312 318 324 330 336 342 348 354 360 366 372 378 384 390 396 402 408 414 420 426 432 438 444 450 456 462 468 474...

result:

ok single line: '0 6 12 18 24 30 36 42 48 54 60... 1512 1518 1524 1530 1536 1542 '

Test #46:

score: 0
Accepted
time: 7ms
memory: 152544kb

input:

500
11 48 33 47 47 22 22 33 18 44 10 8 3 8 37 44 37 44 3 10 8 8 8 3 11 3 37 44 3 8 37 22 33 8 44 47 18 8 47 3 11 11 8 47 11 37 33 44 3 8 47 37 33 37 47 3 8 48 11 18 11 48 37 22 3 44 44 8 8 18 11 22 11 10 8 37 33 44 10 11 47 8 22 8 37 18 11 48 47 11 8 18 48 33 48 11 22 18 33 48 3 8 33 48 33 18 11 48 ...

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 11332 11333 11334 11335 11336 '

Test #47:

score: 0
Accepted
time: 12ms
memory: 153372kb

input:

500
42 48 12 35 24 1 1 27 32 35 48 27 45 45 33 1 36 4 1 24 28 45 15 4 24 26 15 45 12 33 41 9 1 24 45 42 26 45 1 36 35 26 24 32 4 26 9 36 36 33 48 14 35 15 15 32 26 28 41 9 35 1 12 35 48 48 9 14 4 4 48 4 33 41 27 12 36 27 28 41 36 45 41 41 41 27 42 24 41 45 24 9 28 28 48 4 27 45 42 24 45 36 45 32 45 ...

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 11154 11156 11157 11160 11163 '

Test #48:

score: 0
Accepted
time: 8ms
memory: 113720kb

input:

500
39 17 31 31 39 17 39 17 17 31 17 17 39 17 31 17 39 17 17 17 17 31 17 17 31 39 31 39 39 31 39 31 17 39 17 31 31 39 31 31 31 17 17 39 39 39 17 17 17 31 31 17 39 39 39 31 31 31 39 17 31 17 39 17 31 39 31 39 31 39 31 31 17 17 31 17 31 31 39 39 39 31 39 31 39 39 39 39 31 31 31 17 31 39 39 17 39 31 31...

output:

0 8 14 16 22 24 28 30 32 36 38 40 42 44 46 48 50 52 54 56 58 60 62 64 66 68 70 72 74 76 78 80 82 84 86 88 90 92 94 96 98 100 102 104 106 108 110 112 114 116 118 120 122 124 126 128 130 132 134 136 138 140 142 144 146 148 150 152 154 156 158 160 162 164 166 168 170 172 174 176 178 180 182 184 186 188...

result:

ok single line: '0 8 14 16 22 24 28 30 32 36 38... 4996 5002 5004 5010 5018 5026 '

Test #49:

score: 0
Accepted
time: 1ms
memory: 151284kb

input:

500
38 11 32 11 15 23 11 18 23 32 15 11 18 17 11 49 38 11 15 19 32 38 45 47 26 11 50 26 47 17 38 49 19 17 32 45 19 11 50 50 47 19 11 43 38 26 49 47 47 45 20 23 50 45 26 32 50 20 11 15 17 38 47 19 38 15 18 15 45 45 43 17 47 38 19 47 19 32 18 48 43 45 43 48 20 11 15 48 11 20 26 48 47 20 26 23 49 20 15...

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 9698 9699 9700 9701 9702 9703 '

Test #50:

score: 0
Accepted
time: 8ms
memory: 163368kb

input:

500
20 17 40 28 34 13 46 12 49 11 45 16 29 20 35 31 28 43 17 14 23 45 17 3 46 24 31 12 2 13 3 46 2 14 3 14 3 13 29 34 36 23 35 17 12 8 23 27 12 33 35 23 17 40 35 13 40 16 45 13 45 49 8 27 11 33 11 35 42 20 3 12 43 34 4 23 31 29 28 2 28 46 17 3 42 31 2 45 43 11 4 24 35 16 8 12 16 29 34 4 33 14 36 43 ...

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 12270 12271 12273 12274 12277 '

Test #51:

score: 0
Accepted
time: 4ms
memory: 92280kb

input:

307
36 36 30 36 30 36 30 36 30 30 30 39 30 30 36 30 36 39 30 39 30 30 36 30 30 36 36 39 39 36 36 30 36 36 36 30 39 30 36 36 39 39 36 36 36 30 36 30 36 30 39 39 30 30 36 30 39 36 36 36 36 39 39 39 36 36 39 30 30 39 30 30 30 36 30 39 30 36 39 36 39 39 36 36 30 30 39 39 36 36 39 36 30 36 30 36 39 36 36...

output:

0 3 6 9 12 15 18 21 24 27 30 33 36 39 42 45 48 51 54 57 60 63 66 69 72 75 78 81 84 87 90 93 96 99 102 105 108 111 114 117 120 123 126 129 132 135 138 141 144 147 150 153 156 159 162 165 168 171 174 177 180 183 186 189 192 195 198 201 204 207 210 213 216 219 222 225 228 231 234 237 240 243 246 249 25...

result:

ok single line: '0 3 6 9 12 15 18 21 24 27 30 3... 1149 1152 1155 1158 1161 1164 '

Test #52:

score: 0
Accepted
time: 8ms
memory: 144680kb

input:

402
16 44 20 12 44 2 2 9 16 9 2 2 12 16 12 20 12 20 20 12 20 20 16 9 16 16 20 12 9 20 2 16 16 12 20 20 9 2 9 44 2 20 9 9 12 9 16 44 2 2 9 20 44 12 16 2 12 12 20 20 12 44 16 12 2 44 16 44 20 9 20 2 16 16 20 44 2 44 2 20 16 44 2 44 12 16 44 16 9 16 20 44 9 20 9 2 12 9 12 44 44 44 16 12 9 44 20 44 12 4...

output:

0 3 4 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 100 101 102 103 ...

result:

ok single line: '0 3 4 6 7 8 9 10 11 12 13 14 1... 10496 10499 10503 10507 10531 '

Test #53:

score: 0
Accepted
time: 1ms
memory: 151956kb

input:

300
10 21 21 49 29 11 49 21 29 21 10 10 49 29 49 13 29 29 10 13 21 10 49 11 13 13 21 21 11 29 10 11 29 29 21 29 11 10 29 29 29 49 29 11 49 49 11 21 21 49 49 29 21 13 13 49 10 11 11 21 49 29 10 13 10 11 10 21 49 21 13 10 49 21 49 10 21 10 49 49 49 10 10 10 10 49 49 10 13 11 29 29 10 21 10 29 11 49 49...

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 8095 8096 8098 8106 8114 8134 '

Test #54:

score: 0
Accepted
time: 1ms
memory: 89948kb

input:

169
31 31 31 22 37 22 37 37 22 20 37 31 22 31 37 20 37 20 37 37 20 37 31 31 31 31 22 31 22 20 37 22 37 20 20 22 22 31 22 22 20 22 22 20 31 37 22 31 37 31 31 20 20 37 20 22 31 37 37 37 22 20 22 20 22 20 31 37 20 22 37 20 37 20 22 22 37 37 22 31 31 37 22 20 20 37 31 20 37 22 20 22 31 37 31 37 20 22 22...

output:

0 2 4 6 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 100 101 102 103 10...

result:

ok single line: '0 2 4 6 8 9 10 11 12 13 14 15 ... 1589 1590 1592 1595 1601 1607 '

Test #55:

score: 0
Accepted
time: 1ms
memory: 140556kb

input:

443
18 3 18 3 3 44 18 44 3 44 44 3 3 18 3 18 18 18 44 44 18 44 44 18 44 3 3 44 18 44 18 44 3 3 18 44 44 44 44 3 3 3 18 18 3 18 3 3 3 44 18 18 44 3 3 18 3 18 3 18 44 3 44 44 44 18 3 18 3 44 3 3 3 3 44 3 44 3 3 18 44 44 18 18 18 44 44 3 3 44 18 3 18 18 18 44 18 3 18 18 3 3 3 44 3 18 3 18 18 44 18 3 18...

output:

0 15 26 30 41 45 52 56 60 67 71 75 78 82 86 90 93 97 101 104 105 108 112 116 119 120 123 127 130 131 134 135 138 142 145 146 149 150 153 156 157 160 161 164 165 168 171 172 175 176 179 180 182 183 186 187 190 191 194 195 197 198 201 202 205 206 208 209 210 212 213 216 217 220 221 223 224 225 227 228...

result:

ok single line: '0 15 26 30 41 45 52 56 60 67 7...949 9960 9975 9986 10001 10027 '

Test #56:

score: 0
Accepted
time: 3ms
memory: 125144kb

input:

387
28 7 39 28 28 7 28 7 39 28 4 4 28 7 7 28 28 28 28 28 28 39 39 39 28 28 7 39 7 7 39 7 39 39 4 4 39 39 28 28 39 7 39 28 4 4 4 7 39 7 39 39 28 28 4 4 39 39 39 39 39 7 39 28 39 28 28 28 28 28 39 4 28 4 28 39 4 28 7 4 4 7 7 4 39 39 39 4 28 4 4 28 39 7 28 7 7 39 7 7 4 39 28 7 39 7 4 39 28 4 28 4 7 39 ...

output:

0 3 6 9 11 12 14 15 17 18 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 100 101 102 103 104 105 106 107 10...

result:

ok single line: '0 3 6 9 11 12 14 15 17 18 20 2... 7285 7287 7288 7298 7309 7320 '

Test #57:

score: 0
Accepted
time: 3ms
memory: 120468kb

input:

138
46 2 46 2 2 22 46 22 2 2 22 10 15 22 46 10 10 46 22 2 10 46 15 2 46 15 22 10 22 10 2 2 22 46 2 10 22 15 15 15 10 15 15 22 10 22 46 46 15 10 2 46 22 46 22 15 46 46 10 2 22 2 22 15 46 10 22 46 22 10 15 22 2 22 10 22 15 46 22 10 22 15 10 10 10 10 22 15 2 22 10 15 22 2 46 22 10 46 22 22 2 15 15 10 2...

output:

0 5 7 8 10 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 100 101 102 103 104 105 1...

result:

ok single line: '0 5 7 8 10 12 13 14 15 16 17 1... 3619 3623 3631 3636 3643 3667 '

Test #58:

score: 0
Accepted
time: 0ms
memory: 124564kb

input:

259
39 45 13 45 32 13 13 13 46 46 1 32 39 45 46 1 32 1 45 39 39 39 1 32 1 45 39 45 1 1 32 32 39 39 1 1 45 32 32 45 13 1 32 46 45 45 46 13 39 32 32 45 46 1 45 39 45 46 45 39 46 46 45 39 13 1 46 13 13 13 13 46 32 46 32 46 45 1 46 46 32 1 45 45 32 46 45 45 32 1 39 13 45 32 32 46 1 1 45 1 46 1 45 46 13 ...

output:

0 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 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 100 101 10...

result:

ok single line: '0 1 2 3 4 5 6 7 8 9 10 11 12 1... 4122 4123 4124 4125 4126 4127 '

Test #59:

score: 0
Accepted
time: 1ms
memory: 118500kb

input:

183
30 10 30 44 30 44 22 44 30 30 10 22 10 22 30 10 22 22 44 30 30 22 10 22 10 30 30 30 44 10 22 44 22 10 44 10 30 44 22 44 44 44 22 44 30 44 22 30 44 44 44 44 30 10 10 10 44 44 10 30 44 44 44 30 22 44 22 22 30 44 30 22 30 10 30 10 22 44 22 30 10 22 22 30 10 30 44 30 44 30 30 44 44 10 22 44 22 44 30...

output:

0 8 12 14 16 20 22 24 26 28 30 32 34 36 38 40 42 44 46 48 50 52 54 56 58 60 62 64 66 68 70 72 74 76 78 80 82 84 86 88 90 92 94 96 98 100 102 104 106 108 110 112 114 116 118 120 122 124 126 128 130 132 134 136 138 140 142 144 146 148 150 152 154 156 158 160 162 164 166 168 170 172 174 176 178 180 182...

result:

ok single line: '0 8 12 14 16 20 22 24 26 28 30... 2836 2838 2844 2850 2858 2872 '

Test #60:

score: 0
Accepted
time: 3ms
memory: 122508kb

input:

199
5 42 14 34 14 42 14 5 9 14 14 16 5 16 34 42 42 42 5 16 16 14 34 14 14 16 9 16 16 16 9 42 5 9 16 42 16 16 5 42 42 16 34 5 5 14 14 34 5 14 5 16 5 14 42 9 5 16 5 16 42 9 16 16 14 5 16 14 34 14 16 16 16 14 16 34 34 34 9 34 34 14 9 5 9 16 16 16 9 16 14 9 42 14 16 14 9 16 16 42 16 14 9 5 34 9 14 14 9 ...

output:

0 2 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 100 101 102 10...

result:

ok single line: '0 2 4 5 6 7 8 9 10 11 12 13 14... 4420 4422 4424 4432 4440 4448 '

Extra Test:

score: 0
Extra Test Passed