QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#85289#5694. 最后的活动feecle6418AC ✓354ms58516kbC++202.4kb2023-03-07 14:53:422023-03-07 14:53:51

Judging History

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

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-03-07 14:53:51]
  • 评测
  • 测评结果:AC
  • 用时:354ms
  • 内存:58516kb
  • [2023-03-07 14:53:42]
  • 提交

answer

#include<bits/stdc++.h>
using namespace std;
const int N=1e4;
int n,m,c,s[10][4],sum[70];
double u[10][4],v[10][4],f[N+5][10][70],_sum[10][70];
double F(int x,int y,int z){
    if(x==0)return 1;
    if(x<0)return 0;
    if(y>n)return F(x-sum[z],1,0);
    return f[x][y][z];
}
int main(){
    cin>>n>>m>>c;
    for(int i=1;i<=n;i++){
        cin>>s[i][1]>>s[i][2];
        double s1=0,s2=0;
        for(int j=0;j<3;j++)cin>>u[i][j],s1+=u[i][j];
        for(int j=0;j<3;j++)u[i][j]/=s1;
        for(int j=0;j<3;j++)cin>>v[i][j],s2+=v[i][j];
        for(int j=0;j<3;j++)v[i][j]/=s2;
    }
    for(int k=0;k<(1<<n);k++){
        int val=0;
        for(int ll=0;ll<n;ll++){
            if(k&(1<<ll)){
                val+=s[ll+1][1];
            }
            else {
                val+=s[ll+1][2];
            }
        }
        sum[k]=val;
    }
    for(int j=1;j<=n;j++){
        for(int k=0;k<(1<<j-1);k++){
            int val=0;
            for(int ll=0;ll<j-1;ll++){
                if(k&(1<<ll)){
                    val+=s[ll+1][1];
                }
                else {
                    val+=s[ll+1][2];
                }
            }
            _sum[j][k]=val;
        }
    }
    for(int i=1;i<=m;i++){
        double l=0,r=1;
        while(r-l>1e-10){
            double mid=(l+r)/2;
            f[i][1][0]=mid;
            for(int j=n;j>=1;j--){
                for(int k=0;k<(1<<j-1);k++){
                    int val=_sum[j][k];
                    /*for(int ll=0;ll<j-1;ll++){
                        if(k&(1<<ll)){
                            val+=s[ll+1][1];
                        }
                        else {
                            val+=s[ll+1][2];
                        }
                    }*/
                    double res=0;
                    //第一种挑战
                    res=max(res,F(i-(val*c/100),1,0)*u[j][0]+max(F(i,j+1,k+(1<<j-1)),F(i-val-s[j][1],1,0))*u[j][1]+max(F(i,j+1,k),F(i-val-s[j][2],1,0))*u[j][2]);
                    res=max(res,F(i-(val*c/100),1,0)*v[j][0]+max(F(i,j+1,k+(1<<j-1)),F(i-val-s[j][1],1,0))*v[j][1]+max(F(i,j+1,k),F(i-val-s[j][2],1,0))*v[j][2]);
                    f[i][j][k]=res;
                    //cout<<i<<' '<<j<<' '<<k<<' '<<f[i][j][k]<<'\n';
                }
            }
            if(f[i][1][0]<mid)r=mid;
            else l=mid;
            //exit(0);
        }
        printf("%.10lf ",(l+r)/2);
    }
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 37ms
memory: 52092kb

input:

2 10000 16
817 4269 5184 7875 3557 6454 9297 4820
1917 9355 3141 5480 1530 6694 420 324

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 10000 numbers

Test #2:

score: 0
Accepted
time: 25ms
memory: 55792kb

input:

3 10000 28
3324 7744 7865 6120 6618 3395 7381 7383
3843 9935 3068 2797 4685 4077 7151 8796
3116 5415 8936 3217 6278 8499 8765 9127

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 10000 numbers

Test #3:

score: 0
Accepted
time: 79ms
memory: 58336kb

input:

4 10000 94
6763 9644 5765 1067 7530 8467 8061 3062
2216 8375 4097 4133 9782 7823 3386 324
1828 9067 8723 4159 7837 8260 2966 7789
1709 6291 4198 4253 2318 840 4248 9711

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 10000 numbers

Test #4:

score: 0
Accepted
time: 178ms
memory: 58300kb

input:

5 10000 58
4455 6125 8790 6983 9472 542 8310 5693
44 3364 1213 7863 5486 7593 1993 6050
3710 4232 985 354 7980 595 8195 4299
1775 4467 252 5426 4423 9338 2248 8853
622 4208 1354 7877 1890 2174 3406 1198

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 10000 numbers

Test #5:

score: 0
Accepted
time: 353ms
memory: 58516kb

input:

6 10000 38
2576 6294 9290 3107 6523 6704 2991 1088
727 1390 1413 6725 3070 3558 3512 2595
1357 5903 3719 5451 4014 116 1271 1593
3581 7862 873 1566 8829 6566 8209 7559
1956 8120 3116 8111 6549 8383 500 5840
5597 6789 4862 3033 8062 9190 6752 1679

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 10000 numbers

Test #6:

score: 0
Accepted
time: 58ms
memory: 15104kb

input:

6 2013 7
1 9 1132 4086 6135 2836 2688 6
2 4 4375 7225 140 3353 7159 2515
8 9 1001 2601 2978 1787 7580 4862
1 2 484 233 4863 3619 4275 7150
2 4 4617 7191 8194 6131 5594 6147
4 5 5576 3569 7612 8075 1990 7373

output:

0.9996823236 0.9993647481 0.9990472735 0.9987298997 0.9991015569 0.9987849710 0.9984676816 0.9986595035 0.9996416328 0.9996660569 0.9996653858 0.9998177451 0.9998319878 0.9998396424 0.9998381075 0.9998370760 0.9998368758 0.9998372949 0.9998372287 0.9998372094 0.9998372827 0.9998395786 0.9998396169 0...

result:

ok 2013 numbers

Test #7:

score: 0
Accepted
time: 59ms
memory: 14904kb

input:

6 2013 7
4 9 9775 3021 7671 5526 2025 3464
3 4 9126 3934 2914 4291 291 5655
8 9 7263 5087 152 5629 2549 9910
4 7 8908 5673 3606 5616 5767 6650
1 2 8433 6791 4438 3055 6334 9764
2 8 7224 2752 9103 3331 9529 2909

output:

0.8061510351 0.6778851821 0.5668576607 0.8748257623 0.7829296023 0.6698933375 0.7266806076 0.8531219250 0.9800895346 0.8059193081 0.7464820113 0.8927089153 0.9884407935 0.8082579769 0.7441670489 0.8751712430 0.9321241585 0.9658044441 0.8302403181 0.9118942401 0.9884773040 0.9848522995 0.8739655356 0...

result:

ok 2013 numbers

Test #8:

score: 0
Accepted
time: 18ms
memory: 47504kb

input:

1 9989 69
5 14 4391 4602 1426 2032 4387 3854

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.7634372926 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.5828364998 0.0000000000 0.0000000000 0.0000000000 0.4676616916 0.4449591194 0.0000000000 0.0000000000 0.0000000000 0.6059846095 0.3396983855 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9989 numbers

Test #9:

score: 0
Accepted
time: 16ms
memory: 50996kb

input:

2 9931 34
2 16 4842 1497 2215 8299 1001 9059
12 17 8893 2471 2322 7157 8667 6989

output:

0.0000000000 0.4032866379 0.0000000000 0.1626401123 0.6255796362 0.0655905841 0.4086571580 0.0264518062 0.2278676003 0.3913498812 0.1173278708 0.3162777783 0.0575731130 0.2765577298 0.2448205164 0.9704900076 0.2213655172 0.6320321779 0.3739422745 0.3519396603 0.6222467617 0.2277642180 0.4960062196 0...

result:

ok 9931 numbers

Test #10:

score: 0
Accepted
time: 290ms
memory: 58320kb

input:

6 10000 75
12 17 5941 9089 5651 6083 8554 2850
15 16 1449 4599 4027 2389 7574 6518
2 6 4545 5098 2197 7634 5227 484
8 10 2983 1551 7551 1699 1548 3348
12 14 4311 4706 7487 6540 970 3332
5 8 8105 3478 842 1543 2965 212

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.1087288082 0.0000000000 0.0000000000 0.7863136768 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.3833785617 0.0118219537 0.0000000000 0.1971911211 0.2982525612 0.0332564065 0.0000000000 0...

result:

ok 10000 numbers

Test #11:

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

input:

1 9964 94
148 170 8116 6979 1216 719 2141 9139

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9964 numbers

Test #12:

score: 0
Accepted
time: 29ms
memory: 52064kb

input:

2 9943 23
149 429 355 7021 1287 7112 1672 7010
167 217 9863 8869 8739 4075 3948 392

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9943 numbers

Test #13:

score: 0
Accepted
time: 302ms
memory: 58104kb

input:

6 9935 97
268 292 5602 9599 9635 837 6498 6706
411 433 221 6645 3277 7286 4731 1448
242 355 7740 5975 8871 67 586 3436
120 190 828 6716 4946 6986 6140 4112
185 274 4508 5362 9528 6169 8395 4983
216 233 1347 2747 9066 6529 9930 1942

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9935 numbers

Test #14:

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

input:

1 9927 35
1806 4438 8580 1811 5959 7622 2233 8661

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9927 numbers

Test #15:

score: 0
Accepted
time: 183ms
memory: 57896kb

input:

5 9913 42
2573 7669 1322 6501 106 7076 6590 5808
2136 4352 1006 6425 4205 545 9775 2910
2160 8536 797 8965 2006 391 4387 7201
4258 6322 5977 3246 9597 4015 5429 9025
5194 5199 3122 6759 4915 2478 1827 1318

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9913 numbers

Test #16:

score: 0
Accepted
time: 344ms
memory: 57908kb

input:

6 9902 72
3835 7002 8704 1849 2847 5058 5998 4617
5534 7933 3022 9939 6546 5352 4218 1640
2303 7441 7832 1967 2577 4509 8275 3874
1979 9569 1618 8989 83 6535 4728 5932
6167 8104 8456 7086 9395 6428 7209 9934
7908 8336 5478 4632 5198 776 7850 9694

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9902 numbers

Test #17:

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

input:

6 581 5
8497 9573 3169 9983 1707 9208 2994 2676
3750 5635 7528 9585 9441 7637 4844 3909
74 3980 8074 4350 5326 4819 9221 7966
4761 9937 128 5870 3215 4961 5471 9762
5537 6313 9821 1795 1893 3278 4144 8982
7869 9871 6798 605 4873 6331 5965 7971

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 581 numbers

Test #18:

score: 0
Accepted
time: 21ms
memory: 8464kb

input:

6 526 72
1823 4402 4409 4010 9208 6278 7754 8032
2976 5908 8813 5713 6752 6944 1068 1048
611 4030 2808 4564 6638 5955 9732 1183
2262 4225 5263 5835 9037 9782 8562 658
1161 4672 793 2643 7904 771 251 9417
2045 6700 964 1690 5284 6472 1373 2337

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 526 numbers

Test #19:

score: 0
Accepted
time: 16ms
memory: 47444kb

input:

1 9962 94
3987 6797 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9962 numbers

Test #20:

score: 0
Accepted
time: 354ms
memory: 58092kb

input:

6 9967 80
280 3980 0 1 0 0 0 1
415 6559 0 1 0 0 0 1
836 8313 0 1 0 0 0 1
404 5007 0 1 0 0 0 1
6615 7857 0 1 0 0 0 1
423 3396 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9967 numbers

Test #21:

score: 0
Accepted
time: 49ms
memory: 55724kb

input:

3 9925 66
981 5696 0 1 0 0 0 1
2451 4928 0 1 0 0 0 1
1998 3456 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9925 numbers

Test #22:

score: 0
Accepted
time: 349ms
memory: 57956kb

input:

6 9942 100
5389 9074 0 1 0 0 0 1
4466 6210 0 1 0 0 0 1
3074 5979 0 1 0 0 0 1
3105 8350 0 1 0 0 0 1
38 4950 0 1 0 0 0 1
2459 4023 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9942 numbers

Test #23:

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

input:

4 9971 100
9289 9525 0 1 0 0 0 1
1746 9523 0 1 0 0 0 1
5165 6682 0 1 0 0 0 1
642 4080 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9971 numbers

Test #24:

score: 0
Accepted
time: 304ms
memory: 58280kb

input:

6 9992 0
644 966 880 4354 6893 124 8460 4234
322 644 515 4686 6087 8974 4089 9787
644 644 6524 6008 1497 6709 4329 1274
322 966 3651 1322 2893 5286 4184 3910
322 644 6357 7270 1672 2527 820 7639
102 202 1321 1129 7935 3410 3686 8963

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9992 numbers

Test #25:

score: 0
Accepted
time: 289ms
memory: 58404kb

input:

6 9992 0
644 966 880 4354 6893 124 8460 4234
322 644 515 4686 6087 8974 4089 9787
644 644 6524 6008 1497 6709 4329 1274
322 966 3651 1322 2893 5286 4184 3910
322 644 6357 7270 1672 2527 820 7639
102 202 1321 1129 7935 3410 3686 8963

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9992 numbers

Test #26:

score: 0
Accepted
time: 290ms
memory: 58260kb

input:

6 9998 0
432 648 0 1 0 0 0 1
216 648 0 1 0 0 0 1
216 648 0 1 0 0 0 1
432 648 0 1 0 0 0 1
648 864 0 1 0 0 0 1
108 340 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9998 numbers

Test #27:

score: 0
Accepted
time: 313ms
memory: 58432kb

input:

6 9998 0
432 648 0 1 0 0 0 1
216 648 0 1 0 0 0 1
216 648 0 1 0 0 0 1
432 648 0 1 0 0 0 1
648 864 0 1 0 0 0 1
108 340 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9998 numbers

Test #28:

score: 0
Accepted
time: 328ms
memory: 58276kb

input:

6 9990 50
546 546 8979 3728 6220 2952 7541 8232
546 546 4619 8565 905 7238 332 1310
546 546 5750 11 8899 9908 4712 1880
546 546 8527 3554 8720 5044 7815 4265
546 546 8587 4932 8258 64 8368 6705
591 818 4490 8114 4534 2321 3905 2852

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9990 numbers

Test #29:

score: 0
Accepted
time: 301ms
memory: 58396kb

input:

6 9990 50
400 1000 5585 5598 317 6432 1150 5595
600 800 9641 7634 2621 1791 884 9226
400 400 9971 6793 687 6156 5135 7776
400 800 1 5724 4281 8354 3668 6574
400 1000 2043 788 340 7557 5521 130
258 386 7313 6648 2013 3123 9487 7959

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9990 numbers

Test #30:

score: 0
Accepted
time: 305ms
memory: 58312kb

input:

6 9995 50
592 592 0 1 0 0 0 1
592 592 0 1 0 0 0 1
592 592 0 1 0 0 0 1
592 592 0 1 0 0 0 1
592 592 0 1 0 0 0 1
427 963 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9995 numbers

Test #31:

score: 0
Accepted
time: 311ms
memory: 58412kb

input:

6 9995 50
592 592 0 1 0 0 0 1
592 592 0 1 0 0 0 1
592 592 0 1 0 0 0 1
592 592 0 1 0 0 0 1
592 592 0 1 0 0 0 1
427 963 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9995 numbers

Test #32:

score: 0
Accepted
time: 305ms
memory: 58324kb

input:

6 9997 100
270 990 6033 9082 7272 9026 7135 3798
90 90 6829 7499 5391 1845 7400 3511
90 810 5360 7277 7400 8227 3482 2026
90 270 4291 9008 4056 4458 1003 8355
540 900 5203 8756 5741 5804 1636 6108
372 489 8752 1314 2012 9849 6662 3493

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9997 numbers

Test #33:

score: 0
Accepted
time: 295ms
memory: 58328kb

input:

6 9999 100
186 558 7538 2529 7080 4521 376 4414
186 558 9219 9885 7137 4319 2315 393
372 558 3565 901 2666 2604 7438 1822
372 930 3061 8835 1326 7308 1084 6500
744 930 4915 7552 8130 5445 2343 8197
433 466 4674 4807 4244 5004 1068 8936

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9999 numbers

Test #34:

score: 0
Accepted
time: 329ms
memory: 58316kb

input:

6 9999 100
486 972 0 1 0 0 0 1
972 972 0 1 0 0 0 1
486 972 0 1 0 0 0 1
486 486 0 1 0 0 0 1
972 972 0 1 0 0 0 1
685 918 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9999 numbers

Test #35:

score: 0
Accepted
time: 325ms
memory: 58440kb

input:

6 9999 100
486 972 0 1 0 0 0 1
972 972 0 1 0 0 0 1
486 972 0 1 0 0 0 1
486 486 0 1 0 0 0 1
972 972 0 1 0 0 0 1
685 918 0 1 0 0 0 1

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9999 numbers

Test #36:

score: 0
Accepted
time: 350ms
memory: 58440kb

input:

6 9997 75
36 3697 2591 4058 8446 2441 2834 1270
62 8886 8556 2144 3786 8399 3409 5675
47 7237 6917 9867 3282 6619 226 7063
99 6906 799 9363 3258 200 2400 5184
65 9829 1650 368 3286 1656 2494 6294
62 1199 8476 9493 5681 7776 6304 3552

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9997 numbers

Test #37:

score: 0
Accepted
time: 346ms
memory: 58488kb

input:

6 9996 50
99 4197 2812 9850 9750 5818 5396 6304
39 3186 2310 4657 8625 6710 428 5275
43 6409 2364 6843 422 6023 3263 3234
29 6723 9555 3184 4568 2686 7890 9926
64 5173 9876 9652 773 3606 706 2585
26 6244 3749 283 819 9122 1905 6078

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9996 numbers

Test #38:

score: 0
Accepted
time: 332ms
memory: 58280kb

input:

6 9996 93
3100 3857 7917 8570 5324 6585 1460 1591
688 717 5310 798 2573 3486 4939 1787
400 634 2747 3166 7710 9792 6489 7615
481 964 199 8802 4284 1348 7353 4474
393 963 7294 5795 6136 3802 3996 4674
460 481 4998 2774 8957 40 1451 2776

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9996 numbers

Test #39:

score: 0
Accepted
time: 346ms
memory: 58508kb

input:

6 9999 94
3215 3438 2008 3244 8706 7176 1750 4977
103 130 3735 7774 6630 1708 212 3398
773 779 4360 7230 5447 1126 5754 8546
146 514 5269 9997 7358 4805 5776 155
174 555 1931 6696 3426 1018 8341 4772
546 671 1161 5788 2471 4788 8730 8840

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9999 numbers

Test #40:

score: 0
Accepted
time: 328ms
memory: 58456kb

input:

6 9999 94
3215 3438 2008 3244 8706 7176 1750 4977
103 130 3735 7774 6630 1708 212 3398
773 779 4360 7230 5447 1126 5754 8546
146 514 5269 9997 7358 4805 5776 155
174 555 1931 6696 3426 1018 8341 4772
546 671 1161 5788 2471 4788 8730 8840

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9999 numbers

Test #41:

score: 0
Accepted
time: 325ms
memory: 58304kb

input:

6 9997 65
9999 10000 8691 8337 8744 8457 4158 9665
464 722 4817 8601 7188 6331 3029 7867
304 430 4984 9927 567 3710 1810 9242
372 579 6740 6782 3092 938 6823 2092
459 521 6721 860 7812 7130 5857 2982
65 240 966 7637 2438 2844 4737 2308

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9997 numbers

Test #42:

score: 0
Accepted
time: 297ms
memory: 58460kb

input:

6 9990 2
31 44 9672 646 206 9634 1166 1909
5 7 9746 247 598 9693 902 798
6 7 9030 1645 1315 9716 1316 1905
3 7 9257 522 165 9963 1849 521
7 7 9673 1202 110 9129 1425 1257
2594 3808 9577 1033 756 9344 1385 1759

output:

0.9993403511 0.9986811374 0.9980223585 0.9973640141 0.9967061041 0.9960486280 0.9953915857 0.9947349768 0.9940788009 0.9934230580 0.9927677476 0.9921128694 0.9914584233 0.9908044088 0.9901508258 0.9894976740 0.9888449530 0.9881926625 0.9875408024 0.9868893722 0.9862383717 0.9855878007 0.9849376588 0...

result:

ok 9990 numbers

Test #43:

score: 0
Accepted
time: 294ms
memory: 58232kb

input:

6 9993 2
40 41 9076 199 614 9936 674 468
3 7 9325 135 141 9267 560 1848
5 7 9507 1905 355 9991 126 1121
3 6 9432 729 1315 9278 588 375
4 5 9002 1811 1071 9595 1499 424
2543 4167 9903 1786 1633 9238 7 1015

output:

0.9984145460 0.9968316058 0.9952511753 0.9936732504 0.9920978272 0.9905249018 0.9889544702 0.9873865284 0.9858210726 0.9842580988 0.9826976030 0.9811395812 0.9795840297 0.9780309443 0.9764803213 0.9749321568 0.9733864468 0.9718431874 0.9703023748 0.9687640051 0.9672280745 0.9656945790 0.9641635148 0...

result:

ok 9993 numbers

Test #44:

score: 0
Accepted
time: 301ms
memory: 58456kb

input:

6 10000 1
33 50 9367 670 1222 9764 402 933
3 5 9802 1853 1795 9245 47 1485
6 10 9297 1497 1539 9820 636 397
4 8 9867 1158 1997 9609 116 1224
6 8 9754 1905 1568 9265 1001 652
10000 10000 9927 971 165 9481 802 1277

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 10000 numbers

Test #45:

score: 0
Accepted
time: 318ms
memory: 58312kb

input:

6 9997 1
27 35 9585 1452 543 9365 1873 1739
8 10 9591 1964 79 9253 1140 1105
12 12 9011 1599 1062 9040 1494 1038
5 7 9590 1072 344 9152 1863 79
8 12 9265 1462 1586 9490 62 1892
9999 10000 9845 751 1097 9753 266 1687

output:

0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0.0000000000 0...

result:

ok 9997 numbers

Test #46:

score: 0
Accepted
time: 328ms
memory: 58428kb

input:

6 10000 1
1 10000 10000 10000 1 10000 10000 1
1 10000 10000 10000 1 10000 10000 1
1 10000 10000 10000 1 10000 10000 1
1 10000 10000 10000 1 10000 10000 1
1 10000 10000 10000 1 10000 10000 1
1 10000 10000 10000 1 10000 10000 1

output:

0.9999000100 0.9998000300 0.9997000600 0.9996001000 0.9995001499 0.9994002099 0.9993002799 0.9992003598 0.9991004498 0.9990005498 0.9989006596 0.9988007796 0.9987009095 0.9986010494 0.9985011993 0.9984013591 0.9983015289 0.9982017087 0.9981018986 0.9980020983 0.9979023081 0.9978025278 0.9977027576 0...

result:

ok 10000 numbers