Seems people can't read the rules. Trouble is that Cody's "test cases" can't test for existence of disallowed operators in the code.
Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
%%
n = 0;
y_correct = 0;
tolerance = 1e-12;
assert(abs(no_mult_div(n)-y_correct)<tolerance);
ans =
0
|
2 | Pass |
%%
n = 0.1;
y_correct = 0.0750;
tolerance = 1e-12;
assert(abs(no_mult_div(n)-y_correct)<tolerance);
ans =
0.0750
|
3 | Pass |
%%
n = 1;
y_correct = 0.7500;
tolerance = 1e-12;
assert(abs(no_mult_div(n)-y_correct)<tolerance);
ans =
0.7500
|
4 | Pass |
%%
n = -1;
y_correct = -0.7500;
tolerance = 1e-12;
assert(abs(no_mult_div(n)-y_correct)<tolerance);
ans =
-0.7500
|
Rotate input square matrix 90 degrees CCW without rot90
380 Solvers
5460 Solvers
Change the first and last diagonal element of the identity matrix to zero
117 Solvers
Matlab Basics II - Count rows in a matrix
255 Solvers
2770 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!