Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
N = 1;
P=1;
M=0;
hope_correct = 1;
assert(fate(N,P,M)>hope_correct*0.999)
ans =
1
|
2 | Pass |
N = 1;
P=0;
M=1;
hope_correct = 1;
assert(fate(N,P,M)>hope_correct*0.999)
ans =
1
|
3 | Pass |
N=1;
P=1;
M=1;
hope_correct = 0.3679;
assert(fate(N,P,M)>hope_correct*0.999)
ans =
0.3679
|
4 | Pass |
N=2;
P=1;
M=1;
hope_correct = 0.3679;
assert(fate(N,P,M)>hope_correct*0.999)
ans =
0.3679
|
5 | Pass |
N=2;
P=1;
M=2;
hope_correct = 0.1353;
assert(fate(N,P,M)<hope_correct*1.1)
ans =
0.1353
|
6 | Pass |
N=2;
P=2;
M=2;
hope_correct = 0.0183;
assert(fate(N,P,M)<hope_correct*1.1)
%%
ans =
0.0183
|
1091 Solvers
1366 Solvers
Number of 1s in the Binary Representation of a Number
356 Solvers
284 Solvers
Compute a dot product of two vectors x and y
750 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!