QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#424951#3284. Medical CheckupNYCU_template#AC ✓9ms6060kbC++201.2kb2024-05-29 20:07:222024-05-29 20:07:23

Judging History

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

  • [2024-05-29 20:07:23]
  • 评测
  • 测评结果:AC
  • 用时:9ms
  • 内存:6060kb
  • [2024-05-29 20:07:22]
  • 提交

answer

#include <algorithm>
// #include <bits/stdc++.h>
#include <deque>
#include <cmath>
#include <iostream>
#include <queue>
#include <stdio.h>
#include <set>
#include <map>
#include <tuple>
#include <vector>
using namespace std;
#define ll long long
#define fastio ios::sync_with_stdio(false), cin.tie(0);
#define pll pair<ll, ll>
#define pdd pair<double, double>
#define F first
#define S second
#define pb push_back
#define ppb pop_back
#define mkp make_pair
#define sz(a) (ll) a.size()
#define all(x) x.begin(), x.end()
#define rep(i, n) for (ll i = 0; i < n; i++)
#define lowbit(x) x &(-x)

const ll MAXN = 1e5 + 5;
// const ll MAXM = 1e2 + 5;
const ll INF = 1e18;
const ll MOD = 1e9 + 7;

ll N, T;
ll h[MAXN], pre[MAXN], preMax[MAXN];

void solve(){
  cin >> N >> T;  
  for(int i = 1; i <= N; i++){
    cin >> h[i];
    pre[i] = pre[i-1] + h[i];
    preMax[i] = max(preMax[i-1], h[i]);
  }
  for(int i = 1; i <= N; i++){
    if(T == 0 || (T < pre[i])){
      cout << "1\n";
    }
    else cout << max((T - pre[i]), 0ll) / preMax[i] + 2 << "\n";
  }
}

signed main() {
  fastio ll T = 1;
  // cin >> T;
  for (ll i = 1; i <= T; i++) {
    solve();
  }
  return 0;
}

詳細信息

Test #1:

score: 100
Accepted
time: 0ms
memory: 5636kb

input:

1 0
8404

output:

1

result:

ok single line: '1'

Test #2:

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

input:

1 1
141237625

output:

1

result:

ok single line: '1'

Test #3:

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

input:

1 0
1

output:

1

result:

ok single line: '1'

Test #4:

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

input:

1 1
1

output:

2

result:

ok single line: '2'

Test #5:

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

input:

1 2
1

output:

3

result:

ok single line: '3'

Test #6:

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

input:

1 1000000000
1

output:

1000000001

result:

ok single line: '1000000001'

Test #7:

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

input:

2 50000
5
68

output:

10001
736

result:

ok 2 lines

Test #8:

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

input:

2 50000
94
68

output:

532
532

result:

ok 2 lines

Test #9:

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

input:

35 917428
7671
10389
16620
692
1070
10595
13424
154
7669
1337
8350
13736
11780
18609
16924
10539
1840
13079
8321
14024
18207
15244
5250
950
14722
6565
12653
15129
19821
7307
4941
19652
14454
15068
13031

output:

120
88
55
55
55
54
53
53
53
53
52
51
50
44
43
43
43
42
42
41
40
39
39
39
38
37
37
36
33
33
32
31
31
30
29

result:

ok 35 lines

Test #10:

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

input:

45 8271901
29985
29600
28434
28230
27415
27277
27140
26930
26658
26542
26048
24835
23107
22996
22846
22087
21763
20654
18950
18887
15893
15489
15136
15022
14820
14596
14333
13934
13093
11525
10779
9572
8313
8248
8182
7985
7134
4996
3762
2723
2213
2181
1817
1503
477

output:

276
275
274
273
273
272
271
270
269
268
267
266
266
265
264
263
263
262
261
261
260
260
259
259
258
258
257
257
256
256
256
255
255
255
254
254
254
254
254
253
253
253
253
253
253

result:

ok 45 lines

Test #11:

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

input:

2222 923456789
299747
299740
299633
299502
299499
299377
299292
299165
298632
298410
298154
297738
297666
297568
297563
297472
296903
296821
296393
296348
296241
296209
296156
296125
296077
296031
295963
295921
295766
295659
295641
295489
295186
295004
294983
294662
294622
294609
294399
294293
29414...

output:

3081
3080
3079
3078
3077
3076
3075
3074
3073
3072
3071
3070
3069
3068
3067
3066
3065
3064
3063
3062
3061
3060
3059
3058
3057
3056
3055
3054
3053
3053
3052
3051
3050
3049
3048
3047
3046
3045
3044
3043
3042
3041
3040
3039
3038
3037
3036
3035
3034
3033
3032
3031
3030
3029
3028
3027
3026
3025
3024
3023
...

result:

ok 2222 lines

Test #12:

score: 0
Accepted
time: 9ms
memory: 5944kb

input:

100000 1000000000
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
...

output:

200000001
200000000
199999999
199999998
199999997
199999996
199999995
199999994
199999993
199999992
199999991
199999990
199999989
199999988
199999987
199999986
199999985
199999984
199999983
199999982
199999981
199999980
199999979
199999978
199999977
199999976
199999975
199999974
199999973
199999972
...

result:

ok 100000 lines

Test #13:

score: 0
Accepted
time: 9ms
memory: 6020kb

input:

100000 1000000000
4
3
4
4
5
1
3
1
5
1
2
4
4
3
3
1
1
4
4
2
3
1
4
5
4
5
4
1
5
5
2
3
1
1
5
2
3
3
5
5
5
1
2
3
2
5
1
4
5
2
2
2
5
1
3
1
3
1
4
4
3
2
4
4
5
3
3
1
2
5
4
4
5
4
1
1
2
5
2
5
2
4
1
3
1
3
5
5
2
5
4
3
3
2
1
3
1
5
1
5
3
2
4
3
5
4
5
4
3
1
1
3
2
5
4
2
3
5
1
3
3
3
5
1
2
3
3
4
4
5
2
2
1
4
4
3
3
3
2
4
5
...

output:

250000001
250000000
249999999
249999998
199999998
199999997
199999997
199999997
199999996
199999995
199999995
199999994
199999993
199999993
199999992
199999992
199999992
199999991
199999990
199999990
199999989
199999989
199999988
199999987
199999986
199999985
199999985
199999984
199999983
199999982
...

result:

ok 100000 lines

Test #14:

score: 0
Accepted
time: 9ms
memory: 5940kb

input:

100000 1000000000
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:

1000000001
1000000000
999999999
999999998
999999997
999999996
999999995
999999994
999999993
999999992
999999991
999999990
999999989
999999988
999999987
999999986
999999985
999999984
999999983
999999982
999999981
999999980
999999979
999999978
999999977
999999976
999999975
999999974
999999973
99999997...

result:

ok 100000 lines

Test #15:

score: 0
Accepted
time: 9ms
memory: 6052kb

input:

100000 1000000000
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
...

output:

200000001
200000000
199999999
199999998
199999997
199999996
199999995
199999994
199999993
199999992
199999991
199999990
199999989
199999988
199999987
199999986
199999985
199999984
199999983
199999982
199999981
199999980
199999979
199999978
199999977
199999976
199999975
199999974
199999973
199999972
...

result:

ok 100000 lines

Test #16:

score: 0
Accepted
time: 9ms
memory: 6020kb

input:

100000 1000000000
5
1
5
3
4
2
5
4
1
5
5
3
2
4
5
5
3
1
2
1
4
3
3
2
4
2
2
2
4
3
1
2
4
5
5
5
4
2
5
1
2
5
3
1
2
4
1
4
4
1
4
4
5
4
2
5
2
1
2
1
4
2
3
5
4
4
1
5
5
5
1
5
3
1
5
4
5
5
1
5
3
3
5
3
3
1
1
5
5
4
5
5
2
4
5
3
5
2
2
1
2
5
1
5
4
1
2
2
1
2
1
3
1
1
2
4
4
2
2
2
2
4
3
1
4
1
4
2
4
3
3
4
3
5
1
4
5
2
2
5
4
...

output:

200000001
200000000
199999999
199999999
199999998
199999998
199999997
199999996
199999996
199999995
199999994
199999993
199999993
199999992
199999991
199999990
199999989
199999989
199999989
199999988
199999988
199999987
199999986
199999986
199999985
199999985
199999984
199999984
199999983
199999983
...

result:

ok 100000 lines

Test #17:

score: 0
Accepted
time: 6ms
memory: 5936kb

input:

100000 1000000000
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:

1000000001
1000000000
999999999
999999998
999999997
999999996
999999995
999999994
999999993
999999992
999999991
999999990
999999989
999999988
999999987
999999986
999999985
999999984
999999983
999999982
999999981
999999980
999999979
999999978
999999977
999999976
999999975
999999974
999999973
99999997...

result:

ok 100000 lines

Test #18:

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

input:

100000 1000000000
100000
99997
99996
99995
99995
99994
99993
99993
99993
99992
99992
99991
99988
99987
99986
99986
99985
99983
99982
99981
99981
99981
99979
99978
99977
99975
99975
99974
99974
99972
99971
99969
99969
99968
99968
99968
99967
99966
99964
99963
99962
99962
99960
99959
99954
99950
99950...

output:

10001
10000
9999
9998
9997
9996
9995
9994
9993
9992
9991
9990
9989
9988
9987
9986
9985
9984
9983
9982
9981
9980
9979
9978
9977
9976
9975
9974
9973
9972
9971
9970
9969
9968
9967
9966
9965
9964
9963
9962
9961
9960
9959
9958
9957
9956
9955
9954
9953
9952
9951
9950
9949
9948
9947
9946
9945
9944
9943
994...

result:

ok 100000 lines

Test #19:

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

input:

100000 1000000000
13379
48630
79458
85613
36953
31731
69053
22161
33220
93930
12589
69101
22359
56524
53370
44949
15967
41614
76856
61709
90810
69483
51325
80519
16362
74763
90205
11951
43913
8173
47875
94570
64428
95763
18250
10753
12886
64978
35658
77850
65797
3786
25905
59589
69243
18042
12778
40...

output:

74745
20564
12585
11679
11679
11679
11678
11677
11677
10642
10642
10641
10641
10641
10640
10639
10639
10639
10638
10637
10636
10636
10635
10634
10634
10633
10632
10632
10632
10632
10631
10558
10558
10425
10425
10425
10425
10424
10424
10423
10422
10422
10422
10421
10420
10420
10420
10420
10419
10419
...

result:

ok 100000 lines

Test #20:

score: 0
Accepted
time: 5ms
memory: 5980kb

input:

100000 1000000000
1
1
1
6
6
7
9
10
10
10
11
11
11
14
16
16
17
17
17
18
19
19
19
22
22
22
23
24
25
26
27
28
28
29
33
35
35
39
39
40
42
42
43
44
46
46
48
48
48
50
50
50
52
53
53
54
57
58
61
61
61
62
62
62
62
64
65
68
68
68
70
73
74
81
82
83
83
84
84
85
86
86
92
92
94
96
98
98
99
99
100
100
100
100
102...

output:

1000000001
1000000000
999999999
166666667
166666666
142857141
111111109
99999997
99999996
99999995
90909086
90909085
90909084
71428565
62499994
62499993
58823522
58823521
58823520
55555545
52631568
52631567
52631566
45454534
45454533
45454532
43478247
41666652
39999985
38461523
37037022
35714270
357...

result:

ok 100000 lines

Test #21:

score: 0
Accepted
time: 6ms
memory: 5944kb

input:

100000 1000000000
999984117
999969068
999949531
999938004
999901867
999885005
999876541
999867966
999863807
999861102
999853948
999853279
999851262
999846238
999845154
999844560
999833842
999823714
999816175
999809006
999804450
999792190
999789763
999778875
999770766
999763267
999762232
999736564
99...

output:

2
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
1
1
1
1
...

result:

ok 100000 lines

Test #22:

score: 0
Accepted
time: 9ms
memory: 5936kb

input:

100000 1000000000
264101828
984458267
502335158
988775746
51752309
70180328
552250493
249713517
752033981
420114249
32466724
207375527
152116053
35212614
186658750
773736403
100500813
121267322
177899851
665559133
883772932
501015245
279842828
329223266
263815167
461514134
822848810
899004814
952702...

output:

4
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
1
1
1
1
...

result:

ok 100000 lines

Test #23:

score: 0
Accepted
time: 6ms
memory: 5940kb

input:

100000 1000000000
9082
19233
46454
46966
75513
81305
93899
100707
120246
121199
129652
143595
157227
158621
159021
160483
164223
165750
166629
170741
194985
196392
199110
210397
213897
236404
261241
272203
285100
292090
296172
304018
327924
331362
332057
346528
367345
368056
368575
372615
384186
408...

output:

110108
51994
21527
21291
13242
12297
10647
9927
8313
8246
7708
6959
6354
6298
6281
6223
6080
6023
5990
5845
5117
5080
5009
4740
4661
4217
3815
3660
3494
3409
3361
3274
3034
3002
2994
2868
2705
2699
2694
2664
2582
2426
2311
2305
2223
2134
2014
1969
1919
1901
1878
1841
1800
1786
1695
1651
1642
1593
15...

result:

ok 100000 lines

Test #24:

score: 0
Accepted
time: 9ms
memory: 6004kb

input:

100000 1000000000
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:

1000000001
1000000000
999999999
999999998
999999997
999999996
999999995
999999994
999999993
999999992
999999991
999999990
999999989
999999988
999999987
999999986
999999985
999999984
999999983
999999982
999999981
999999980
999999979
999999978
999999977
999999976
999999975
999999974
999999973
99999997...

result:

ok 100000 lines

Test #25:

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

input:

100000 1000000000
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
...

output:

500000001
500000000
499999999
499999998
499999997
499999996
499999995
499999994
499999993
499999992
499999991
499999990
499999989
499999988
499999987
499999986
499999985
499999984
499999983
499999982
499999981
499999980
499999979
499999978
499999977
499999976
499999975
499999974
499999973
499999972
...

result:

ok 100000 lines

Test #26:

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

input:

100000 1000000000
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
3
...

output:

333333334
333333333
333333332
333333331
333333330
333333329
333333328
333333327
333333326
333333325
333333324
333333323
333333322
333333321
333333320
333333319
333333318
333333317
333333316
333333315
333333314
333333313
333333312
333333311
333333310
333333309
333333308
333333307
333333306
333333305
...

result:

ok 100000 lines

Test #27:

score: 0
Accepted
time: 9ms
memory: 5948kb

input:

100000 1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000...

output:

2
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
1
1
1
1
...

result:

ok 100000 lines

Test #28:

score: 0
Accepted
time: 6ms
memory: 6060kb

input:

100000 0
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
1000000000
10000...

output:

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
1
1
1
1
1
...

result:

ok 100000 lines

Test #29:

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

input:

100000 100000
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
2
...

output:

50001
50000
49999
49998
49997
49996
49995
49994
49993
49992
49991
49990
49989
49988
49987
49986
49985
49984
49983
49982
49981
49980
49979
49978
49977
49976
49975
49974
49973
49972
49971
49970
49969
49968
49967
49966
49965
49964
49963
49962
49961
49960
49959
49958
49957
49956
49955
49954
49953
49952
...

result:

ok 100000 lines

Test #30:

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

input:

100000 100000
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
...

output:

20001
20000
19999
19998
19997
19996
19995
19994
19993
19992
19991
19990
19989
19988
19987
19986
19985
19984
19983
19982
19981
19980
19979
19978
19977
19976
19975
19974
19973
19972
19971
19970
19969
19968
19967
19966
19965
19964
19963
19962
19961
19960
19959
19958
19957
19956
19955
19954
19953
19952
...

result:

ok 100000 lines