Test | Status | Code Input and Output |
---|---|---|
1 | Fail |
a = 1;
b = 2;
c_correct = sqrt(5);
tolerance = 1e-12 ;
assert(abs(hypotenuse(a,b)-c_correct)<tolerance);
c =
0.4794
|
2 | Fail |
a = 3;
b = 4;
c_correct = 5;
tolerance = 1e-12 ;
assert(abs(hypotenuse(a,b)-c_correct)<tolerance);
c =
0.6816
|
3 | Fail |
a = 5;
b = 12;
c_correct = 13;
tolerance = 1e-12 ;
assert(abs(hypotenuse(a,b)-c_correct)<tolerance);
c =
0.4047
|
482 Solvers
Given a 4x4 matrix, swap the two middle columns
515 Solvers
convert matrix to single column
306 Solvers
400 Solvers
429 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!