Cody

Solution 2184677

Submitted on 31 Mar 2020
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Fail
C = 0; lim = 5; N_correct = 5; assert(isequal(mandelbrot(C,lim),N_correct))

Index exceeds the number of array elements (1). Error in mandelbrot (line 5) c = C(i); Error in Test1 (line 4) assert(isequal(mandelbrot(C,lim),N_correct))

2   Pass
C = [0 0.5; 1 4]; lim = 5; N_correct = [5 4; 2 1]; assert(isequal(mandelbrot(C,lim),N_correct))

3   Fail
i = sqrt(-1); C = [i 1 -2*i -2]; lim = 10; N_correct = [10 2 1 10]; assert(isequal(mandelbrot(C,lim),N_correct))

Index exceeds the number of array elements (4). Error in mandelbrot (line 5) c = C(i); Error in Test3 (line 5) assert(isequal(mandelbrot(C,lim),N_correct))

Suggested Problems

More from this Author95