problem in the test suite my Solution was perfect, please update the test suite
I'm not sure how you reach that conclusion. The example given says fib(5) should be 5. Your code returns 15.
Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
%%
n = 1;
f = 1;
assert(isequal(fib(n),f))
|
2 | Fail |
%%
n = 6;
f = 8;
assert(isequal(fib(n),f))
Error: Assertion failed.
|
3 | Pass |
%%
n = 10;
f = 55;
assert(isequal(fib(n),f))
|
4 | Fail |
%%
n = 20;
f = 6765;
assert(isequal(fib(n),f))
Error: Assertion failed.
|
9828 Solvers
321 Solvers
Convert a Cell Array into an Array
430 Solvers
2455 Solvers
492 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!