CSES - IZhO 2018, day 2 - Results
Submission details
Task:Segments
Sender:Lieska
Submission time:2019-02-28 13:26:30 +0200
Language:C++
Status:READY
Result:0
Feedback
groupverdictscore
#10
#20
#30
#40
#50
#60
Test results
testverdicttimegroup
#1ACCEPTED0.01 s1, 5, 6details
#2ACCEPTED0.02 s1, 4, 5, 6details
#30.01 s1, 4, 5, 6details
#40.02 s1, 4, 5, 6details
#5ACCEPTED0.10 s1, 2, 4, 5, 6details
#6ACCEPTED0.13 s1, 2, 4, 5, 6details
#70.03 s1, 4, 5, 6details
#80.03 s1, 4, 5, 6details
#90.03 s1, 4, 5, 6details
#100.04 s1, 4, 5, 6details
#11ACCEPTED0.14 s1, 2, 4, 5, 6details
#12ACCEPTED0.14 s1, 2, 4, 5, 6details
#130.03 s1, 5, 6details
#140.02 s1, 5, 6details
#150.01 s1, 5, 6details
#160.02 s1, 5, 6details
#170.03 s1, 5, 6details
#180.02 s1, 5, 6details
#190.02 s1, 5, 6details
#200.03 s1, 5, 6details
#21--2, 4, 5, 6details
#22--2, 4, 5, 6details
#23--2, 4, 5, 6details
#24--2, 4, 5, 6details
#25--2, 4, 5, 6details
#26--2, 4, 5, 6details
#27--2, 5, 6details
#28--2, 5, 6details
#29--2, 5, 6details
#30--2, 5, 6details
#31--2, 5, 6details
#32--2, 5, 6details
#330.05 s3, 4, 5, 6details
#340.05 s3, 4, 5, 6details
#350.06 s3, 4, 5, 6details
#360.04 s3, 4, 5, 6details
#37--2, 3, 4, 5, 6details
#38--2, 3, 4, 5, 6details
#39--2, 3, 4, 5, 6details
#40--2, 3, 4, 5, 6details
#412.80 s3, 4, 5, 6details
#420.80 s3, 4, 5, 6details
#430.06 s3, 4, 5, 6details
#440.48 s3, 4, 5, 6details
#450.42 s3, 4, 5, 6details
#460.22 s3, 4, 5, 6details
#470.17 s3, 4, 5, 6details
#480.10 s3, 4, 5, 6details
#49--2, 3, 4, 5, 6details
#50--2, 3, 4, 5, 6details
#51--2, 3, 4, 5, 6details
#52--2, 3, 4, 5, 6details
#530.06 s3, 5, 6details
#540.35 s3, 5, 6details
#550.39 s3, 5, 6details
#560.30 s3, 5, 6details
#570.04 s3, 5, 6details
#580.04 s3, 5, 6details
#590.04 s3, 5, 6details
#600.05 s3, 5, 6details
#611.58 s3, 5, 6details
#620.52 s3, 5, 6details
#631.86 s3, 5, 6details
#640.99 s3, 5, 6details
#650.40 s3, 5, 6details
#660.17 s3, 5, 6details
#670.96 s3, 5, 6details
#680.94 s3, 5, 6details
#690.04 s4, 5, 6details
#700.04 s4, 5, 6details
#710.05 s4, 5, 6details
#720.05 s4, 5, 6details
#73--2, 4, 5, 6details
#74--2, 4, 5, 6details
#75--2, 4, 5, 6details
#76--2, 4, 5, 6details
#770.20 s4, 5, 6details
#780.85 s4, 5, 6details
#790.09 s4, 5, 6details
#802.01 s4, 5, 6details
#810.55 s4, 5, 6details
#820.31 s4, 5, 6details
#831.64 s4, 5, 6details
#840.76 s4, 5, 6details
#85--2, 4, 5, 6details
#86--2, 4, 5, 6details
#87--2, 4, 5, 6details
#88--2, 4, 5, 6details
#890.06 s4, 5, 6details
#900.06 s4, 5, 6details
#910.05 s4, 5, 6details
#920.04 s4, 5, 6details
#93--2, 4, 5, 6details
#94--2, 4, 5, 6details
#95--2, 4, 5, 6details
#96--2, 4, 5, 6details
#970.65 s4, 5, 6details
#981.93 s4, 5, 6details
#991.32 s4, 5, 6details
#1000.97 s4, 5, 6details
#1010.13 s4, 5, 6details
#1020.14 s4, 5, 6details
#1031.24 s4, 5, 6details
#1040.28 s4, 5, 6details
#105--2, 4, 5, 6details
#106--2, 4, 5, 6details
#107--2, 4, 5, 6details
#108--2, 4, 5, 6details
#1090.29 s5, 6details
#1100.32 s5, 6details
#1111.64 s5, 6details
#1121.12 s5, 6details
#1130.04 s5, 6details
#1140.04 s5, 6details
#1150.06 s5, 6details
#1160.05 s5, 6details
#1170.37 s5, 6details
#1180.11 s5, 6details
#1190.07 s5, 6details
#1200.33 s5, 6details
#1211.31 s5, 6details
#1220.40 s5, 6details
#1230.15 s5, 6details
#1240.14 s5, 6details
#1250.07 s6details
#1260.07 s6details
#1270.08 s6details
#1280.09 s6details
#1290.08 s6details
#1300.07 s6details
#131--6details
#132--6details
#1330.25 s6details
#134--6details
#1350.25 s6details
#136--6details
#1370.25 s6details
#1380.24 s6details
#1390.25 s6details
#1400.24 s6details
#1410.25 s6details
#1420.12 s6details
#1430.32 s6details
#1440.09 s6details
#1450.26 s6details
#1461.33 s6details
#1470.31 s6details
#1480.31 s6details
#149--6details
#150--6details
#151--6details
#152--6details
#153--6details
#154--6details
#1550.18 s6details
#1560.35 s6details
#1570.25 s6details
#1580.25 s6details
#1590.25 s6details
#1602.06 s6details
#1610.07 s6details
#1620.07 s6details
#1630.08 s6details
#1640.07 s6details
#1650.08 s6details
#1660.08 s6details
#1670.24 s6details
#1680.24 s6details
#1690.25 s6details
#1700.24 s6details
#1710.25 s6details
#1720.61 s6details
#1730.24 s6details
#1741.24 s6details
#1750.25 s6details
#1760.23 s6details
#1770.25 s6details
#1780.25 s6details

Code

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
long long n, a, b, k, la=0;
long double t;
multiset<pair<int, int>> s;
int v[100001][2];
set<int> r;
void f(int c, int d){
    int e=la*t;
    c^=e;
    d^=e;
    if (c>d) swap (c,d);
    s.insert({c,d});
    auto it=r.begin();
    v[*it][0]=c;
    v[*it][1]=d;
    r.erase(*it);
}
void g(int c){
    int d=v[c][0];
    int e=v[c][1];
    s.erase(s.find({d,e}));
    r.insert(c);
}
int h(int c, int d, int e){
    int m=la*t;
    c^=m;
    d^=m;
    if (c>d) swap (c,d);
    auto it=s.begin();
    int l=0;
    if (d-c+1>=e){
        while (it!=s.end()){
            if (it->second>=d && it->first<=c) l++;
            else if (it->second<=d && it->first>=c && it->second-it->first+1>=e) l++;
            else if (d>=it->second && c>=it->first && it->second-c+1>=e) l++;
            else if (d<=it->second && c<=it->first && d-it->first+1>=e) l++;
            it++;
        }
    }
    la=l;
    return l;
}
int main(){
    cin >> n >> t;
    for (int i=1; i<=n; ++i) r.insert(i);
    for (int i=0; i<n; ++i){
        cin >> a;
        if (a==1){
            cin >> a >> b;
            f(a, b);
        }
        else if (a==2){
            cin >> b;
            g(b);
        }
        else {
            cin >> a >> b >> k;
            cout << h(a,b,k) << "\n";
        }
    }
}

Test details

Test 1

Group: 1, 5, 6

Verdict: ACCEPTED

input
6 1
1 1 2
3 2 4 2
1 3 5
3 2 3 1
...

correct output
0
2
0

user output
0
2
0

Test 2

Group: 1, 4, 5, 6

Verdict: ACCEPTED

input
6 0
1 3 10
1 3 5
3 6 10 6
2 1
...

correct output
0
2

user output
0
2

Test 3

Group: 1, 4, 5, 6

Verdict:

input
4997 0
1 833442202 930205491
2 1
1 504293454 957786495
1 224595672 257664075
...

correct output
1
1
0
0
1
...

user output
1
1
0
0

Error:
free(): invalid pointer

Test 4

Group: 1, 4, 5, 6

Verdict:

input
5000 0
1 857518164 942592543
3 769062011 894891994 93011017...

correct output
0
1
1
0
1
...

user output
0
1
1
0
1

Error:
free(): invalid pointer

Test 5

Group: 1, 2, 4, 5, 6

Verdict: ACCEPTED

input
4997 0
1 276298097 854422443
1 563996342 988032427
1 51686976 955883623
1 529822223 611241635
...

correct output
2313
1462
2392
2866
1327
...

user output
2313
1462
2392
2866
1327
...
Truncated

Test 6

Group: 1, 2, 4, 5, 6

Verdict: ACCEPTED

input
4996 0
1 541082646 986908997
1 298130872 612261120
1 418743866 838629719
1 578177879 599595930
...

correct output
1325
351
766
1028
1817
...

user output
1325
351
766
1028
1817
...
Truncated

Test 7

Group: 1, 4, 5, 6

Verdict:

input
4997 0
1 673104529 769337281
1 517717376 641289051
1 691531515 822324029
1 484422967 829694258
...

correct output
286
116
15
139
245
...

user output
286
116
15
139
245

Error:
free(): invalid pointer

Test 8

Group: 1, 4, 5, 6

Verdict:

input
4996 0
1 566790360 910881695
1 673799823 886847089
1 544186074 699983102
1 390472771 819277166
...

correct output
481
466
870
958
357
...

user output
481
466
870
958
357
...
Truncated

Error:
free(): invalid pointer

Test 9

Group: 1, 4, 5, 6

Verdict:

input
4997 0
1 311894481 985154124
1 93348771 548779687
1 61713035 894798574
1 130684134 837309545
...

correct output
1914
1156
452
1765
1054
...

user output
1914
1156
452
1765
1054
...
Truncated

Error:
free(): invalid pointer

Test 10

Group: 1, 4, 5, 6

Verdict:

input
4998 0
1 5244228 999429458
1 182233237 675050048
1 208304660 710405973
1 57929563 968788399
...

correct output
1497
3411
3080
2813
3341
...

user output
1497
3411
3080
2813
3341
...
Truncated

Error:
free(): invalid pointer

Test 11

Group: 1, 2, 4, 5, 6

Verdict: ACCEPTED

input
5000 0
1 138010223 980534871
1 499966259 764536451
1 672136573 685265804
1 80302878 418348032
...

correct output
700
406
717
739
325
...

user output
700
406
717
739
325
...
Truncated

Test 12

Group: 1, 2, 4, 5, 6

Verdict: ACCEPTED

input
4997 0
1 173311381 288193192
1 646739115 740744470
1 664909127 700628166
1 927098660 986334861
...

correct output
773
723
558
290
268
...

user output
773
723
558
290
268
...
Truncated

Test 13

Group: 1, 5, 6

Verdict:

input
5000 1
1 47948970 959769780
1 614627473 762470577
1 932708021 972547145
1 831646816 935362452
...

correct output
1792
1624
1539
978
1658
...

user output
1792
1624
1539
978
1658
...
Truncated

Test 14

Group: 1, 5, 6

Verdict:

input
4997 1
1 156729482 611924319
1 765173610 942616735
1 390453146 862270256
1 834618680 910039272
...

correct output
108
384
83
551
897
...

user output
108
384
83
551
897
...
Truncated

Error:
free(): invalid pointer

Test 15

Group: 1, 5, 6

Verdict:

input
5000 1
1 861013531 977347829
3 865535687 974039280 67816177...

correct output
1
0
0
0
0
...

user output
1
0
0

Error:
free(): invalid pointer

Test 16

Group: 1, 5, 6

Verdict:

input
4997 1
1 853504444 995735390
2 1
1 322187402 960024719
3 937111821 988885006 47862574...

correct output
0
1
1
2
4
...

user output
0
1

Error:
free(): invalid pointer

Test 17

Group: 1, 5, 6

Verdict:

input
4996 1
1 688414964 793930038
1 109917926 659398500
1 76284729 884484379
1 376095180 960087764
...

correct output
741
138
559
444
140
...

user output
741
138
559
444
140
...
Truncated

Error:
free(): invalid pointer

Test 18

Group: 1, 5, 6

Verdict:

input
4997 1
1 920871184 936695573
1 659402711 973644268
1 479653358 591830103
1 574679216 706066169
...

correct output
666
801
1717
921
239
...

user output
666
801
1717
921
239
...
Truncated

Error:
free(): invalid pointer

Test 19

Group: 1, 5, 6

Verdict:

input
4999 1
1 147904862 693674916
1 570066544 643428923
1 290247277 385578940
1 116096366 982831461
...

correct output
369
90
923
712
480
...

user output
369
90
923
712
480
...
Truncated

Error:
free(): invalid pointer

Test 20

Group: 1, 5, 6

Verdict:

input
5000 1
1 809870390 838103302
1 399931927 836524386
1 313146599 810470390
1 50767309 991565965
...

correct output
597
52
127
856
199
...

user output
597
52
127
856
199
...

Error:
free(): invalid pointer

Test 21

Group: 2, 4, 5, 6

Verdict:

input
99999 0
1 542278648 752847919
1 908853324 973602007
1 588424789 980155304
1 372139172 973021807
...

correct output
12393
9698
14602
23357
15947
...

user output
(empty)

Test 22

Group: 2, 4, 5, 6

Verdict:

input
99996 0
1 383312433 961881075
1 96037351 120173826
1 388851451 789202579
1 33024422 662291471
...

correct output
17233
1775
4481
9205
4289
...

user output
(empty)

Test 23

Group: 2, 4, 5, 6

Verdict:

input
99999 0
1 533289475 546894472
1 39931522 494372686
1 874792749 958963107
1 322293110 886546924
...

correct output
11537
15592
14968
4596
19382
...

user output
(empty)

Test 24

Group: 2, 4, 5, 6

Verdict:

input
99999 0
1 789020477 831531475
1 721360156 831499064
1 157611858 763297379
1 522416008 883915173
...

correct output
2090
29734
16631
6672
20242
...

user output
(empty)

Test 25

Group: 2, 4, 5, 6

Verdict:

input
99998 0
1 414593051 789086453
1 393691216 562684591
1 895017281 966815439
1 82218330 567268130
...

correct output
38793
24160
61332
25918
14515
...

user output
(empty)

Test 26

Group: 2, 4, 5, 6

Verdict:

input
99996 0
1 774547793 975864094
1 987857589 989981159
1 40171230 102860728
1 165500086 424331562
...

correct output
2028
24344
10985
12218
28105
...

user output
(empty)

Test 27

Group: 2, 5, 6

Verdict:

input
99999 1
1 501458848 643726421
1 703650678 986108579
1 265780182 290237122
1 930863188 931593632
...

correct output
9199
10166
20275
13377
3401
...

user output
(empty)

Test 28

Group: 2, 5, 6

Verdict:

input
99997 1
1 802453266 926235294
1 596396700 742099088
1 654549298 887244917
1 605464028 860636478
...

correct output
23034
5944
20353
4597
26407
...

user output
(empty)

Test 29

Group: 2, 5, 6

Verdict:

input
99998 1
1 539297318 867790360
1 825382930 853475626
1 216154900 722970169
1 810709740 948980107
...

correct output
15880
21316
2060
4667
8428
...

user output
(empty)

Test 30

Group: 2, 5, 6

Verdict:

input
99998 1
1 505680552 865322648
1 74774102 647062421
1 99534849 223650285
1 570197508 917954083
...

correct output
5982
6715
2486
6751
602
...

user output
(empty)

Test 31

Group: 2, 5, 6

Verdict:

input
99998 1
1 776563090 879700066
1 521008676 658637861
1 188299903 397585496
1 472287402 801987130
...

correct output
16166
12290
5443
11087
2319
...

user output
(empty)

Test 32

Group: 2, 5, 6

Verdict:

input
99998 1
1 468237965 902949629
1 440849852 909287640
1 937394869 975577991
1 341966840 733861689
...

correct output
18456
3608
12205
20852
34678
...

user output
(empty)

Test 33

Group: 3, 4, 5, 6

Verdict:

input
99999 0
1 26849685 522971850
3 27837228 670015966 1
2 1
1 622102578 815127224
...

correct output
1
1
2
0
0
...

user output
1
1
2
0
0

Error:
free(): invalid pointer

Test 34

Group: 3, 4, 5, 6

Verdict:

input
100000 0
1 281928108 862908770
2 1
1 877603460 891739898
2 2
...

correct output
0
4
4
0
2
...

user output
(empty)

Error:
free(): invalid pointer

Test 35

Group: 3, 4, 5, 6

Verdict:

input
99999 0
1 431429356 664152817
1 502587988 704980092
3 862329391 901181257 1
3 50480843 97710010 1
...

correct output
0
0
1
4
2
...

user output
0
0
1
4
2
...

Error:
free(): invalid pointer

Test 36

Group: 3, 4, 5, 6

Verdict:

input
99998 0
1 266842596 769294439
3 64417878 140787231 1
1 709336996 935392606
3 115521741 918448329 1
...

correct output
0
2
1
1
1
...

user output
0
2
1

Error:
free(): invalid pointer

Test 37

Group: 2, 3, 4, 5, 6

Verdict:

input
99996 0
1 857133065 858912382
1 156573323 906358079
1 535386545 965684783
1 116489983 316375650
...

correct output
43411
4197
41837
29041
15538
...

user output
(empty)

Test 38

Group: 2, 3, 4, 5, 6

Verdict:

input
99999 0
1 833998750 952091079
1 480221557 982269889
1 546263089 617354864
1 296367176 743945062
...

correct output
20254
39314
33189
26716
22357
...

user output
(empty)

Test 39

Group: 2, 3, 4, 5, 6

Verdict:

input
99999 0
1 314422233 617084374
1 720983060 724224808
1 217770304 269741473
1 235903743 980515571
...

correct output
28693
34800
24864
50414
53283
...

user output
(empty)

Test 40

Group: 2, 3, 4, 5, 6

Verdict:

input
99997 0
1 299684796 874716881
1 133145702 889048591
1 31954914 112519525
1 118523682 775918225
...

correct output
44918
51555
72197
67862
35661
...

user output
(empty)

Test 41

Group: 3, 4, 5, 6

Verdict:

input
99999 0
1 280692644 684497361
1 703060617 921307557
1 809494381 972291352
1 87704385 141807557
...

correct output
43724
30863
57884
12041
66373
...

user output
43724
30863
57884
12041
66373
...
Truncated

Error:
free(): invalid pointer

Test 42

Group: 3, 4, 5, 6

Verdict:

input
100000 0
1 985508247 999409542
1 626267407 839081763
1 138843399 518645186
1 713641460 829194352
...

correct output
18727
51865
41149
56531
21014
...

user output
18727
51865
41149
56531
21014
...
Truncated

Error:
free(): invalid pointer

Test 43

Group: 3, 4, 5, 6

Verdict:

input
99997 0
1 989329226 999371306
1 328448123 942079241
1 891139653 991554178
1 118558759 526981807
...

correct output
2039
2172
1096
2755
1363
...

user output
2039
2172
1096
2755
1363
...
Truncated

Error:
free(): invalid pointer

Test 44

Group: 3, 4, 5, 6

Verdict:

input
99999 0
1 998771714 999138403
1 268642467 900271230
1 420569370 539307128
1 559820496 907937136
...

correct output
30832
41579
43885
39698
17575
...

user output
30832
41579
43885
39698
17575
...
Truncated

Error:
free(): invalid pointer

Test 45

Group: 3, 4, 5, 6

Verdict:

input
99998 0
1 96230180 861768980
1 185999372 971870093
1 994336 999720809
1 75231972 850671604
...

correct output
10552
32999
54980
40297
38453
...

user output
10552
32999
54980
40297
38453
...
Truncated

Error:
free(): invalid pointer

Test 46

Group: 3, 4, 5, 6

Verdict:

input
99996 0
1 41866954 725224780
1 61833959 905739354
1 685709669 819640450
1 310830073 715044628
...

correct output
21288
7748
12877
14065
9231
...

user output
21288
7748
12877
14065
9231
...
Truncated

Test 47

Group: 3, 4, 5, 6

Verdict:

input
99999 0
1 374122730 946147998
1 91698044 816340156
1 31179637 910322192
1 39157314 890909568
...

correct output
19724
17103
23833
15080
21010
...

user output
19724
17103
23833
15080
21010
...
Truncated

Error:
free(): invalid pointer

Test 48

Group: 3, 4, 5, 6

Verdict:

input
100000 0
1 94376062 995768447
1 206460609 596073241
1 372482346 520674504
1 23030876 835041441
...

correct output
11627
3484
10530
10309
14049
...

user output
11627
3484
10530
10309
14049
...
Truncated

Error:
free(): invalid pointer

Test 49

Group: 2, 3, 4, 5, 6

Verdict:

input
100000 0
1 422729907 910917698
1 493973639 553319621
1 911957218 920343633
1 81831012 312586991
...

correct output
16688
8282
21130
7640
44044
...

user output
(empty)

Test 50

Group: 2, 3, 4, 5, 6

Verdict:

input
99998 0
1 951638645 967850130
1 247044969 259081092
1 868510788 898062780
1 222245858 774582021
...

correct output
28912
31760
28161
11491
18688
...

user output
(empty)

Test 51

Group: 2, 3, 4, 5, 6

Verdict:

input
99999 0
1 254181859 989818079
1 170002821 249350246
1 365239083 414873769
1 154747095 620098837
...

correct output
15722
16494
13671
34351
28830
...

user output
(empty)

Test 52

Group: 2, 3, 4, 5, 6

Verdict:

input
100000 0
1 82504833 715930858
1 900733078 942633165
1 995441470 997613991
1 125554655 657547694
...

correct output
23646
33815
24471
3275
21476
...

user output
(empty)

Test 53

Group: 3, 5, 6

Verdict:

input
100000 1
1 579860190 679298391
1 138340427 410019252
1 863220885 868895876
1 229949008 261969650
...

correct output
2441
2424
3559
2098
1227
...

user output
2441
2424
3559
2098
1227
...
Truncated

Test 54

Group: 3, 5, 6

Verdict:

input
99998 1
1 850364243 859961185
1 617671694 783088913
1 911000726 982609913
1 112120424 397807680
...

correct output
2423
11129
27389
17738
22766
...

user output
2423
11129
27389
17738
22766
...
Truncated

Error:
free(): invalid pointer

Test 55

Group: 3, 5, 6

Verdict:

input
99997 1
1 673568161 769713189
1 666945292 808101384
1 406568409 555282827
1 914202069 945781121
...

correct output
26648
25452
18051
841
13397
...

user output
26648
25452
18051
841
13397
...
Truncated

Error:
free(): invalid pointer

Test 56

Group: 3, 5, 6

Verdict:

input
99997 1
1 969985039 975479473
1 452091654 685128257
1 221674546 386811576
1 517952639 851642688
...

correct output
16599
16128
28209
10017
14680
...

user output
16599
16128
28209
10017
14680
...
Truncated

Error:
free(): invalid pointer

Test 57

Group: 3, 5, 6

Verdict:

input
99999 1
1 16723339 156693663
2 1
1 21637394 36622379
1 739106023 935549903
...

correct output
0
1
1
0
0
...

user output
0

Error:
free(): invalid pointer

Test 58

Group: 3, 5, 6

Verdict:

input
99996 1
1 214489517 447564388
1 127578019 154915617
3 581627260 594616521 1
1 890714132 971365150
...

correct output
0
2
0
1
1
...

user output
0
2
0

Test 59

Group: 3, 5, 6

Verdict:

input
100000 1
1 754448561 972186367
3 736877979 980392642 1
1 425544220 633998038
2 2
...

correct output
1
1
1
1
1
...

user output
1
1
1

Error:
free(): invalid pointer

Test 60

Group: 3, 5, 6

Verdict:

input
100000 1
1 98176209 609470411
1 984873509 997964327
2 2
1 715795344 718704433
...

correct output
0
2
3
1
1
...

user output
(empty)

Error:
free(): invalid pointer

Test 61

Group: 3, 5, 6

Verdict:

input
99997 1
1 440830617 486265188
1 718959263 736246884
1 289784424 990563447
1 782914462 908347748
...

correct output
17966
23927
20735
22838
35109
...

user output
17966
23927
20735
22838
35109
...
Truncated

Error:
free(): invalid pointer

Test 62

Group: 3, 5, 6

Verdict:

input
100000 1
1 519872898 871170335
1 768769096 939498664
1 442336526 579818931
1 862622209 900433427
...

correct output
47354
24735
22621
29069
52071
...

user output
47354
24735
22621
29069
52071
...
Truncated

Error:
free(): invalid pointer

Test 63

Group: 3, 5, 6

Verdict:

input
99998 1
1 852497337 878014774
1 259750803 290775293
1 944048464 992626218
1 178362819 902293480
...

correct output
46111
38020
11591
36622
13448
...

user output
46111
38020
11591
36622
13448
...
Truncated

Error:
free(): invalid pointer

Test 64

Group: 3, 5, 6

Verdict:

input
100000 1
1 586669695 672645477
1 337922450 464120323
1 857160866 912503685
1 927580167 972037377
...

correct output
9669
21228
31664
24272
29815
...

user output
9669
21228
31664
24272
29815
...
Truncated

Error:
free(): invalid pointer

Test 65

Group: 3, 5, 6

Verdict:

input
99996 1
1 463269248 731187898
1 65668940 786526860
1 3672225 976533233
1 536356501 657569191
...

correct output
51459
16040
39751
51977
12657
...

user output
51459
16040
39751
51977
12657
...
Truncated

Test 66

Group: 3, 5, 6

Verdict:

input
99996 1
1 158973713 329894499
1 330388520 666277461
1 609921382 670124976
1 227133625 967813037
...

correct output
21034
15164
17947
15445
15099
...

user output
21034
15164
17947
15445
15099
...
Truncated

Error:
free(): invalid pointer

Test 67

Group: 3, 5, 6

Verdict:

input
99996 1
1 51258498 223428366
1 96867934 860167694
1 328162598 616379307
1 690859919 914909205
...

correct output
45465
46326
24751
45587
34056
...

user output
45465
46326
24751
45587
34056
...
Truncated

Error:
free(): invalid pointer

Test 68

Group: 3, 5, 6

Verdict:

input
100000 1
1 270800174 407326295
1 118585439 918389985
1 620428084 824821712
1 41105413 504620987
...

correct output
56734
12797
6685
46902
19623
...

user output
56734
12797
6685
46902
19623
...
Truncated

Error:
free(): invalid pointer

Test 69

Group: 4, 5, 6

Verdict:

input
99956 0
1 832255809 852671034
2 1
1 631759492 856591874
3 963202188 991654171 5074934
...

correct output
0
1
0
0
3
...

user output
0

Error:
free(): invalid pointer

Test 70

Group: 4, 5, 6

Verdict:

input
99927 0
1 346186419 406385335
1 421695192 571276460
1 448847222 890296399
1 585041172 699724236
...

correct output
0
1
2
4
2
...

user output
0
1

Error:
free(): invalid pointer

Test 71

Group: 4, 5, 6

Verdict:

input
99905 0
1 522396009 977947002
3 7109337 795224266 474398792
2 1
1 386561329 698483417
...

correct output
0
0
0
1
1
...

user output
0

Error:
free(): invalid pointer

Test 72

Group: 4, 5, 6

Verdict:

input
99907 0
1 279590014 487890507
2 1
1 22708888 782569744
3 207298060 973149365 48017936...

correct output
1
0
1
0
0
...

user output
1

Error:
free(): invalid pointer

Test 73

Group: 2, 4, 5, 6

Verdict:

input
99920 0
1 405521140 594167669
1 282364748 831650562
1 405186586 764435149
1 602040750 901959485
...

correct output
15796
17859
28338
23419
14696
...

user output
(empty)

Test 74

Group: 2, 4, 5, 6

Verdict:

input
99985 0
1 415087946 485581258
1 989803000 993626928
1 703275177 940951248
1 936319823 968617461
...

correct output
3964
3199
3046
367
1189
...

user output
(empty)

Test 75

Group: 2, 4, 5, 6

Verdict:

input
99933 0
1 936416841 944031553
1 856024024 888476131
1 580181273 889743326
1 998070812 999035885
...

correct output
30523
19572
12428
22942
1740
...

user output
(empty)

Test 76

Group: 2, 4, 5, 6

Verdict:

input
99932 0
1 862286600 882751144
1 73199599 169934158
1 839570676 848922789
1 256475026 354518041
...

correct output
6350
7926
1826
2964
6686
...

user output
(empty)

Test 77

Group: 4, 5, 6

Verdict:

input
99953 0
1 892248356 958422320
1 318165037 585334462
1 156925430 630784880
1 595418378 879553072
...

correct output
15737
10209
14846
9392
5298
...

user output
15737
10209
14846
9392
5298
...
Truncated

Test 78

Group: 4, 5, 6

Verdict:

input
99952 0
1 142048454 777647051
1 420290251 457915446
1 912200768 953134707
1 937077365 950461331
...

correct output
17142
40948
6733
12272
25979
...

user output
17142
40948
6733
12272
25979
...
Truncated

Error:
free(): invalid pointer

Test 79

Group: 4, 5, 6

Verdict:

input
99925 0
1 465213968 775713791
1 844211838 924387956
1 194305808 636276359
1 106552296 887409943
...

correct output
2892
5517
3781
4582
3161
...

user output
2892
5517
3781
4582
3161
...
Truncated

Error:
free(): invalid pointer

Test 80

Group: 4, 5, 6

Verdict:

input
99948 0
1 754780904 989476139
1 773721055 901061042
1 648693422 731256373
1 657479886 998141549
...

correct output
6255
32135
24618
32011
31336
...

user output
6255
32135
24618
32011
31336
...
Truncated

Test 81

Group: 4, 5, 6

Verdict:

input
99974 0
1 327305131 988450448
1 69697289 972923230
1 95985156 959952780
1 205420088 902891371
...

correct output
18881
13555
24230
18532
22578
...

user output
18881
13555
24230
18532
22578
...
Truncated

Error:
free(): invalid pointer

Test 82

Group: 4, 5, 6

Verdict:

input
99931 0
1 197576581 494174134
1 50866149 986020088
1 123323079 660428369
1 265558440 831266786
...

correct output
9547
22980
9313
19013
16107
...

user output
9547
22980
9313
19013
16107
...
Truncated

Error:
free(): invalid pointer

Test 83

Group: 4, 5, 6

Verdict:

input
99902 0
1 574479070 975336391
1 300284341 943560434
1 49810801 800732463
1 29572872 366200490
...

correct output
58509
27673
31713
39300
64412
...

user output
58509
27673
31713
39300
64412
...
Truncated

Error:
free(): invalid pointer

Test 84

Group: 4, 5, 6

Verdict:

input
99963 0
1 118545256 817595632
1 331772418 766865415
1 440099552 466448284
1 473676443 819257147
...

correct output
38282
17432
55135
20974
18241
...

user output
38282
17432
55135
20974
18241
...
Truncated

Error:
free(): invalid pointer

Test 85

Group: 2, 4, 5, 6

Verdict:

input
99981 0
1 447539169 635842884
1 786979587 919446190
1 871254218 884556828
1 801953293 862480506
...

correct output
5483
15241
12717
9905
10716
...

user output
(empty)

Test 86

Group: 2, 4, 5, 6

Verdict:

input
99910 0
1 231548194 396942055
1 641143679 688872425
1 361203200 839512139
1 912592218 912882732
...

correct output
11972
6039
3589
10520
1826
...

user output
(empty)

Test 87

Group: 2, 4, 5, 6

Verdict:

input
99961 0
1 81042540 154018168
1 362862269 675658549
1 666748436 896032442
1 210736877 622913856
...

correct output
11541
17400
10726
26967
19239
...

user output
(empty)

Test 88

Group: 2, 4, 5, 6

Verdict:

input
99905 0
1 311892110 539845991
1 447412848 581753017
1 153984162 606685567
1 866305395 943178806
...

correct output
24145
2060
36597
19833
1575
...

user output
(empty)

Test 89

Group: 4, 5, 6

Verdict:

input
99980 0
1 140140059 747417219
2 1
1 845133614 868616682
2 2
...

correct output
0
0
0
0
0
...

user output
(empty)

Error:
free(): invalid pointer

Test 90

Group: 4, 5, 6

Verdict:

input
99934 0
1 511926400 749350222
1 591934516 900046322
1 807733157 852839374
1 217693852 876940574
...

correct output
2
3
1
4
3
...

user output
2

Test 91

Group: 4, 5, 6

Verdict:

input
99968 0
1 778319699 990022375
2 1
1 41502247 305012691
3 288372340 976349323 52794455...

correct output
0
0
0
0
0
...

user output
0

Error:
free(): invalid pointer

Test 92

Group: 4, 5, 6

Verdict:

input
99937 0
1 603779778 979585683
3 713303723 987108399 25268678...

correct output
1
0
2
0
0
...

user output
1

Error:
free(): invalid pointer

Test 93

Group: 2, 4, 5, 6

Verdict:

input
99916 0
1 406353317 769653254
1 353342260 919077862
1 773521728 853776928
1 650912615 861461934
...

correct output
21981
10346
7611
14092
3833
...

user output
(empty)

Test 94

Group: 2, 4, 5, 6

Verdict:

input
99952 0
1 996512255 999983911
1 715943580 956279148
1 671678874 928731164
1 546328264 986509606
...

correct output
319
2837
2690
2184
3480
...

user output
(empty)

Test 95

Group: 2, 4, 5, 6

Verdict:

input
99996 0
1 715984569 904584042
1 617365196 894745750
1 716927314 894055370
1 789261959 858015693
...

correct output
13428
20345
29757
11142
14799
...

user output
(empty)

Test 96

Group: 2, 4, 5, 6

Verdict:

input
99905 0
1 106165497 327808665
1 981145822 986203317
1 185530081 652385060
1 532188123 927099160
...

correct output
1903
2502
2079
864
2375
...

user output
(empty)

Test 97

Group: 4, 5, 6

Verdict:

input
99994 0
1 660612922 792322193
1 134578914 507516191
1 921671494 991717183
1 65064368 129004265
...

correct output
12652
10676
10968
33527
12877
...

user output
12652
10676
10968
33527
12877
...
Truncated

Error:
free(): invalid pointer

Test 98

Group: 4, 5, 6

Verdict:

input
99980 0
1 235506667 263041459
1 321296096 468774280
1 563608264 983172821
1 852958840 954649438
...

correct output
28589
6962
35575
29063
22089
...

user output
28589
6962
35575
29063
22089
...
Truncated

Error:
free(): invalid pointer

Test 99

Group: 4, 5, 6

Verdict:

input
99906 0
1 689332409 836634790
1 381309096 467442477
1 568401232 886505694
1 606931623 689868434
...

correct output
30746
27788
281
19741
35963
...

user output
30746
27788
281
19741
35963
...
Truncated

Error:
free(): invalid pointer

Test 100

Group: 4, 5, 6

Verdict:

input
99990 0
1 453830665 832808680
1 940490251 971684299
1 50357811 507085177
1 125795068 466115667
...

correct output
61032
23468
40085
20914
31840
...

user output
61032
23468
40085
20914
31840
...
Truncated

Error:
free(): invalid pointer

Test 101

Group: 4, 5, 6

Verdict:

input
99930 0
1 23468935 750940608
1 725843243 961518419
1 388272912 892016566
1 259665541 540324910
...

correct output
9221
17769
6145
13297
8584
...

user output
9221
17769
6145
13297
8584
...
Truncated

Error:
free(): invalid pointer

Test 102

Group: 4, 5, 6

Verdict:

input
99974 0
1 167000156 669456325
1 145126005 711702705
1 438404590 727087213
1 3511699 954478283
...

correct output
5221
6991
7219
9183
4855
...

user output
5221
6991
7219
9183
4855
...
Truncated

Error:
free(): invalid pointer

Test 103

Group: 4, 5, 6

Verdict:

input
99930 0
1 40348945 992010448
1 50746774 708451265
1 301694931 960121255
1 30373281 675262098
...

correct output
19685
25550
23788
8850
34807
...

user output
19685
25550
23788
8850
34807
...
Truncated

Error:
free(): invalid pointer

Test 104

Group: 4, 5, 6

Verdict:

input
99966 0
1 183347362 700059694
1 219280956 906514681
1 582778779 966296799
1 81575254 976489240
...

correct output
23518
20620
23904
32420
32379
...

user output
23518
20620
23904
32420
32379
...
Truncated

Error:
free(): invalid pointer

Test 105

Group: 2, 4, 5, 6

Verdict:

input
99961 0
1 971878009 997672547
1 4932171 291306621
1 173249182 786069703
1 160216190 269307417
...

correct output
18553
255
22385
11931
23154
...

user output
(empty)

Test 106

Group: 2, 4, 5, 6

Verdict:

input
99911 0
1 797105160 886889615
1 849866517 894388019
1 62719693 399386596
1 95992194 530385432
...

correct output
7554
18427
33196
7047
12714
...

user output
(empty)

Test 107

Group: 2, 4, 5, 6

Verdict:

input
99979 0
1 477305869 843439787
1 805977587 823023502
1 185375937 942023697
1 600007938 734807032
...

correct output
16251
30679
23173
18059
2245
...

user output
(empty)

Test 108

Group: 2, 4, 5, 6

Verdict:

input
99946 0
1 801556379 984602550
1 721997287 759007907
1 81439991 857751920
1 247564249 770224259
...

correct output
23377
17194
27636
11361
14336
...

user output
(empty)

Test 109

Group: 5, 6

Verdict:

input
99926 1
1 55312793 407274170
1 496104310 586693478
1 983769114 997276224
1 759909737 761556594
...

correct output
4295
4794
5467
10395
2990
...

user output
4295
4794
5467
10395
2990
...
Truncated

Error:
free(): invalid pointer

Test 110

Group: 5, 6

Verdict:

input
99916 1
1 52741459 143333054
1 275812707 417352868
1 994866024 998912634
1 773413543 964532295
...

correct output
7780
10632
9904
21447
22705
...

user output
7780
10632
9904
21447
22705
...
Truncated

Error:
free(): invalid pointer

Test 111

Group: 5, 6

Verdict:

input
99934 1
1 446886561 554495469
1 859136256 914535865
1 93901674 569951338
1 942063665 981710041
...

correct output
46213
31850
22831
26849
4815
...

user output
46213
31850
22831
26849
4815
...
Truncated

Error:
free(): invalid pointer

Test 112

Group: 5, 6

Verdict:

input
99949 1
1 354075157 499545674
1 684319198 979551122
1 196625678 670744883
1 358667221 497202349
...

correct output
33195
16621
19948
39603
12846
...

user output
33195
16621
19948
39603
12846
...
Truncated

Test 113

Group: 5, 6

Verdict:

input
99916 1
1 79554907 511545930
2 1
1 78834040 523974758
2 2
...

correct output
0
1
1
0
0
...

user output
(empty)

Error:
free(): invalid pointer

Test 114

Group: 5, 6

Verdict:

input
99971 1
1 170192176 836621139
1 984443454 994323120
3 673099451 750454351 16121327...

correct output
1
0
1
1
1
...

user output
1
0

Error:
free(): invalid pointer

Test 115

Group: 5, 6

Verdict:

input
99923 1
1 149323776 895348404
3 933111762 968583503 7362329
2 1
1 43929027 231689732
...

correct output
0
1
1
0
2
...

user output
0
0
0

Error:
free(): invalid pointer

Test 116

Group: 5, 6

Verdict:

input
99936 1
1 55486360 724110231
2 1
1 558269707 663280861
2 2
...

correct output
0
0
0
0
0
...

user output
(empty)

Error:
free(): invalid pointer

Test 117

Group: 5, 6

Verdict:

input
99965 1
1 187963358 487265721
1 716009003 901399874
1 683573240 870611567
1 361042855 565667045
...

correct output
10481
12426
10029
10536
15329
...

user output
10481
12426
10029
10536
15329
...
Truncated

Test 118

Group: 5, 6

Verdict:

input
99917 1
1 485550916 859922383
1 448767479 860288740
1 393121245 531293730
1 982293792 983119418
...

correct output
2014
5611
7249
6562
7051
...

user output
2014
5611
7249
6562
7051
...
Truncated

Error:
free(): invalid pointer

Test 119

Group: 5, 6

Verdict:

input
99976 1
1 923290623 989097849
1 547302606 658071298
1 657197754 926330468
1 904907815 976456253
...

correct output
4156
6718
3555
2751
885
...

user output
4156
6718
3555
2751
885
...
Truncated

Error:
free(): invalid pointer

Test 120

Group: 5, 6

Verdict:

input
99981 1
1 374738786 431688176
1 390281126 776764169
1 193011109 217684377
1 11366544 864791829
...

correct output
11893
9783
11347
13896
28283
...

user output
11893
9783
11347
13896
28283
...
Truncated

Error:
free(): invalid pointer

Test 121

Group: 5, 6

Verdict:

input
99941 1
1 161329746 185751586
1 108310168 209467704
1 200041993 216438432
1 38503690 973392283
...

correct output
28720
21683
7688
7903
10941
...

user output
28720
21683
7688
7903
10941
...
Truncated

Test 122

Group: 5, 6

Verdict:

input
99962 1
1 405602667 955548166
1 73610651 948043387
1 350879268 370439171
1 611401 999860466
...

correct output
55801
21586
14126
19450
43697
...

user output
55801
21586
14126
19450
43697
...
Truncated

Error:
free(): invalid pointer

Test 123

Group: 5, 6

Verdict:

input
99989 1
1 446329835 868582332
1 309437454 889805813
1 465736515 620459627
1 638676372 766859419
...

correct output
16865
13579
7758
31730
26846
...

user output
16865
13579
7758
31730
26846
...
Truncated

Error:
free(): invalid pointer

Test 124

Group: 5, 6

Verdict:

input
99967 1
1 33832204 951143165
1 117341675 632983487
1 498580433 549753705
1 13907118 984925459
...

correct output
7438
9002
3369
6899
6905
...

user output
7438
9002
3369
6899
6905
...
Truncated

Error:
free(): invalid pointer

Test 125

Group: 6

Verdict:

input
199996 0
1 794557534 925125105
3 378154850 550796146 96714648...

correct output
0
0
0
0
2
...

user output
0

Error:
free(): invalid pointer

Test 126

Group: 6

Verdict:

input
200000 0
1 471950271 535347025
2 1
1 80924409 361744189
1 127230361 235918157
...

correct output
1
1
0
1
2
...

user output
(empty)

Error:
free(): invalid pointer

Test 127

Group: 6

Verdict:

input
199996 0
1 669635486 961780228
1 299301633 925717035
3 409862327 477788566 24790429...

correct output
1
1
0
1
1
...

user output
1
1
0
1
1
...

Error:
free(): invalid pointer

Test 128

Group: 6

Verdict:

input
200000 0
1 249577645 313904382
3 935604200 967803673 12136786...

correct output
0
0
1
0
0
...

user output
0
0
1

Error:
free(): invalid pointer

Test 129

Group: 6

Verdict:

input
200000 0
1 391380366 691563722
1 161084795 359616219
2 1
2 2
...

correct output
0
0
0
3
1
...

user output
0
0
0
3

Error:
free(): invalid pointer

Test 130

Group: 6

Verdict:

input
199998 0
1 362848634 467195794
3 781468882 828241096 3182879
2 1
1 39429399 596285397
...

correct output
0
1
0
0
0
...

user output
0
1

Error:
free(): invalid pointer

Test 131

Group: 6

Verdict:

input
200000 0
1 432191567 454898827
1 775472328 828028736
1 2085884 577757684
1 103069934 815019043
...

correct output
6689
2804
1384
6787
6160
...

user output
(empty)

Test 132

Group: 6

Verdict:

input
199997 0
1 960431250 966379012
1 756249984 773383265
1 214222124 279677182
1 99891112 849760018
...

correct output
9459
31343
27451
25141
25343
...

user output
(empty)

Test 133

Group: 6

Verdict:

input
199996 0
1 795091997 910235751
1 136252676 500143443
1 630338396 813909591
1 987975314 996204524
...

correct output
44976
10275
51274
62116
21607
...

user output
(empty)

Test 134

Group: 6

Verdict:

input
200000 0
1 518640823 595688453
1 199529752 369885518
1 180086299 410317732
1 257849438 868065234
...

correct output
5465
3971
4889
8821
10846
...

user output
(empty)

Test 135

Group: 6

Verdict:

input
199996 0
1 38813973 679809956
1 131345585 787868036
1 192957249 750610367
1 289679897 643060295
...

correct output
38111
41972
41939
42010
34927
...

user output
(empty)

Test 136

Group: 6

Verdict:

input
199999 0
1 371994772 678560879
1 453793146 829121587
1 377652770 637777962
1 945946084 965812622
...

correct output
1375
386
710
242
1094
...

user output
(empty)

Test 137

Group: 6

Verdict:

input
199996 0
1 295427068 699990462
1 900807918 901060638
1 728095116 757972448
1 808984652 964293278
...

correct output
26248
48912
57553
38933
82609
...

user output
(empty)

Test 138

Group: 6

Verdict:

input
199999 0
1 630162314 768929398
1 2717349 362717531
1 965841406 992604508
1 204248303 732799863
...

correct output
15571
31907
29531
90999
53869
...

user output
(empty)

Test 139

Group: 6

Verdict:

input
199997 0
1 447615710 775697510
1 136678452 908666729
1 978207767 997969719
1 245046313 970465425
...

correct output
62497
66538
36622
54825
62740
...

user output
(empty)

Test 140

Group: 6

Verdict:

input
199998 0
1 247843962 828400238
1 651788133 797295053
1 285310276 330117045
1 436346983 580753148
...

correct output
36118
59683
17205
71377
80825
...

user output
(empty)

Test 141

Group: 6

Verdict:

input
200000 0
1 154914743 217289576
1 709471432 954338389
1 728283481 999534237
1 358246037 571329218
...

correct output
39180
43337
67398
63036
34880
...

user output
(empty)

Test 142

Group: 6

Verdict:

input
199998 0
1 182143434 881879429
1 694252846 936022748
1 870684777 981977299
1 319618602 603678766
...

correct output
3495
4738
175
3083
3772
...

user output
3495
4738
175
3083
3772
...
Truncated

Error:
free(): invalid pointer

Test 143

Group: 6

Verdict:

input
199997 0
1 441135881 801463153
1 47987143 798729429
1 508777712 991029135
1 23873410 990450027
...

correct output
470
20349
18621
25391
11951
...

user output
470
20349
18621
25391
11951
...
Truncated

Error:
free(): invalid pointer

Test 144

Group: 6

Verdict:

input
199996 0
1 88360059 600741249
1 726072539 816266741
1 71363901 565953326
1 111209933 945940350
...

correct output
1297
3591
409
3815
739
...

user output
1297
3591
409
3815
739
...
Truncated

Error:
free(): invalid pointer

Test 145

Group: 6

Verdict:

input
199996 0
1 738487676 808572948
1 104947938 995001798
1 725010121 849302916
1 358704556 638549412
...

correct output
87661
107198
110720
73653
139580
...

user output
(empty)

Test 146

Group: 6

Verdict:

input
199999 0
1 246802837 401002645
1 91440292 750518958
1 63550162 135636139
1 380864238 396373607
...

correct output
39382
23541
49142
31669
27911
...

user output
39382
23541
49142
31669
27911
...
Truncated

Error:
free(): invalid pointer

Test 147

Group: 6

Verdict:

input
199998 0
1 7204370 752381172
1 34528366 270366381
1 95086759 388950538
1 29268155 946821757
...

correct output
20738
17400
21043
20019
26941
...

user output
20738
17400
21043
20019
26941
...
Truncated

Error:
free(): invalid pointer

Test 148

Group: 6

Verdict:

input
199997 0
1 70177005 997136545
1 23713123 956131924
1 137619701 629230448
1 72337775 837434939
...

correct output
12150
8083
13699
21298
11760
...

user output
12150
8083
13699
21298
11760
...
Truncated

Test 149

Group: 6

Verdict:

input
199999 0
1 281611622 680123912
1 897980627 982127744
1 316055190 324932564
1 163158528 494073682
...

correct output
57608
6639
67447
21913
4562
...

user output
(empty)

Test 150

Group: 6

Verdict:

input
200000 0
1 909702571 940565229
1 790081510 973197595
1 768017477 909265392
1 883856298 899422496
...

correct output
67016
22679
24470
66779
35816
...

user output
(empty)

Test 151

Group: 6

Verdict:

input
199997 0
1 340576697 454040639
1 109607655 609921364
1 444746316 916175130
1 501785994 545050262
...

correct output
25291
30067
32984
11726
48043
...

user output
(empty)

Test 152

Group: 6

Verdict:

input
199996 0
1 416831419 683360339
1 913212513 914728657
1 930323823 979385626
1 66726064 145314468
...

correct output
16827
19938
13831
34068
33937
...

user output
(empty)

Test 153

Group: 6

Verdict:

input
200000 0
1 641049077 994937423
1 949903405 972117342
1 577164258 798739640
1 487715081 575291661
...

correct output
35123
27905
2524
26639
9997
...

user output
(empty)

Test 154

Group: 6

Verdict:

input
199999 0
1 112036112 627644565
1 548684246 952074849
1 585240687 946712613
1 259380819 884948896
...

correct output
9608
18071
19074
21235
25549
...

user output
(empty)

Test 155

Group: 6

Verdict:

input
199999 1
1 404012068 643811249
1 764136158 837873452
1 634333683 973756208
1 30205093 981870525
...

correct output
7100
1530
1088
6451
1491
...

user output
7100
1530
1088
6451
1491
...
Truncated

Error:
free(): invalid pointer

Test 156

Group: 6

Verdict:

input
199998 1
1 986301851 998638181
1 788693353 975708584
1 857554715 939498862
1 536973687 717770359
...

correct output
3949
14845
3891
7304
16101
...

user output
3949
14845
3891
7304
16101
...
Truncated

Error:
free(): invalid pointer

Test 157

Group: 6

Verdict:

input
199997 1
1 673758362 723869595
1 165019308 864077094
1 454105457 962516496
1 706273569 987944619
...

correct output
66187
63805
21328
52078
31012
...

user output
(empty)

Test 158

Group: 6

Verdict:

input
199996 1
1 557808671 632716744
1 742116228 944399867
1 939865969 953051518
1 562457181 705952436
...

correct output
58060
792
63506
27854
45873
...

user output
(empty)

Test 159

Group: 6

Verdict:

input
200000 1
1 642935948 724455333
1 453953771 933496384
1 169798085 759089250
1 466843130 838408620
...

correct output
18380
7395
13389
19529
37987
...

user output
(empty)

Test 160

Group: 6

Verdict:

input
199998 1
1 26278470 818769319
1 140546798 291336778
1 720218455 862253933
1 24036870 236692167
...

correct output
29591
13155
7085
32030
21263
...

user output
29591
13155
7085
32030
21263
...
Truncated

Error:
free(): invalid pointer

Test 161

Group: 6

Verdict:

input
199997 1
1 520850328 868023808
2 1
1 110572197 144847575
1 514995947 678793156
...

correct output
0
1
2
2
2
...

user output
0
1
1
0

Error:
free(): invalid pointer

Test 162

Group: 6

Verdict:

input
199998 1
1 795842908 991104003
3 532679545 933702095 78140013...

correct output
1
1
1
0
1
...

user output
1

Error:
free(): invalid pointer

Test 163

Group: 6

Verdict:

input
199996 1
1 166031366 619931855
2 1
1 557364406 787532320
2 2
...

correct output
0
0
0
1
0
...

user output
(empty)

Error:
free(): invalid pointer

Test 164

Group: 6

Verdict:

input
199999 1
1 572031229 802870739
1 88789951 332149522
1 564059025 665492952
3 441236952 934159046 20736622...

correct output
1
0
0
0
0
...

user output
1
0
0

Error:
free(): invalid pointer

Test 165

Group: 6

Verdict:

input
199997 1
1 739841886 877889584
2 1
1 377137244 898489563
1 322548985 596324527
...

correct output
0
1
0
0
2
...

user output
(empty)

Error:
free(): invalid pointer

Test 166

Group: 6

Verdict:

input
199997 1
1 30312054 299199974
3 61536553 771572660 356642821...

correct output
0
0
0
0
0
...

user output
0
0
0

Error:
free(): invalid pointer

Test 167

Group: 6

Verdict:

input
200000 1
1 617754739 628239624
1 208177304 837079190
1 896709875 993462303
1 259655557 354512049
...

correct output
62154
67486
46800
57528
13717
...

user output
(empty)

Test 168

Group: 6

Verdict:

input
199997 1
1 71124139 656604786
1 943023884 990138290
1 818737274 921589699
1 53401040 562242888
...

correct output
50289
26556
81880
32020
59677
...

user output
(empty)

Test 169

Group: 6

Verdict:

input
199998 1
1 218086993 565633680
1 112541326 910550645
1 953506655 964062354
1 677375248 746729997
...

correct output
36933
76189
6672
26839
90667
...

user output
(empty)

Test 170

Group: 6

Verdict:

input
199997 1
1 320204878 481889718
1 239575295 684978172
1 933521412 969976352
1 707362743 780966863
...

correct output
54645
90160
14953
11095
47387
...

user output
(empty)

Test 171

Group: 6

Verdict:

input
200000 1
1 187451628 385955991
1 36814592 437145237
1 781029827 783172402
1 825104178 884448693
...

correct output
44792
61344
85315
28921
15966
...

user output
(empty)

Test 172

Group: 6

Verdict:

input
199999 1
1 3076548 709267085
1 765180929 986619698
1 714599416 754750288
1 99031392 847308425
...

correct output
16607
24602
16861
8464
13868
...

user output
16607
24602
16861
8464
13868
...
Truncated

Error:
free(): invalid pointer

Test 173

Group: 6

Verdict:

input
199997 1
1 142986097 931509448
1 266908159 567704713
1 447688847 706294425
1 40582045 951502449
...

correct output
109490
115780
102299
58054
22746
...

user output
(empty)

Test 174

Group: 6

Verdict:

input
200000 1
1 198556505 500282606
1 706456584 969368325
1 189159171 679746573
1 205569096 992107824
...

correct output
46329
43199
7300
34798
43148
...

user output
46329
43199
7300
34798
43148
...
Truncated

Error:
free(): invalid pointer

Test 175

Group: 6

Verdict:

input
199998 1
1 15875414 874350805
1 124074670 929639648
1 3851721 998099036
1 287113588 461418356
...

correct output
76596
80103
82080
96962
29590
...

user output
(empty)

Test 176

Group: 6

Verdict:

input
200000 1
1 20032854 979105593
1 101119147 777277070
1 581411978 941048091
1 23848690 883758222
...

correct output
12574
24839
3914
28007
22024
...

user output
12574
24839
3914
28007
22024
...
Truncated

Error:
free(): invalid pointer

Test 177

Group: 6

Verdict:

input
200000 1
1 419494293 596002979
1 5373272 970287655
1 30954885 890350581
1 606118894 766570662
...

correct output
72978
39303
64757
73754
61087
...

user output
(empty)

Test 178

Group: 6

Verdict:

input
199999 1
1 94116035 964244105
1 498555384 794817372
1 13444948 930041887
1 73845098 780156278
...

correct output
13579
37218
70294
53461
79381
...

user output
(empty)