Cody

Solution 2038031

Submitted on 28 Nov 2019
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
n = 1; y_correct =[0]; assert(isequal(Matrix_Spiral(n),y_correct))

Assertion failed.

2   Fail
n = 2; y_correct =[11 11 0 0]; assert(isequal(Matrix_Spiral(n),y_correct))

Assertion failed.

3   Fail
n = 3; y_correct =[11 11 11 0 0 11 0 0 0]; assert(isequal(Matrix_Spiral(n),y_correct))

Assertion failed.

4   Fail
n = 4; y_correct =[11 11 11 11 0 0 0 11 0 0 11 11 0 0 0 0]; assert(isequal(Matrix_Spiral(n),y_correct))

Assertion failed.

5   Fail
n = 5; y_correct =[11 11 11 11 11 0 0 0 0 11 0 0 11 0 11 0 0 11 11 11 0 0 0 0 0]; assert(isequal(Matrix_Spiral(n),y_correct))

Assertion failed.

6   Fail
n = 10; y_correct =[11 11 11 11 11 11 11 11 11 11 0 0 0 0 0 0 0 0 0 11 0 0 11 11 11 11 11 11 0 11 0 0 11 0 0 0 0 11 0 11 0 0 11 0 11 11 0 11 0 11 0 0 11 0 11 0 0 11 0 11 0 0 11 0 11 11 11 11 0 11 0 0 11 0 0 0 0 0 0 11 0 0 11 11 11 11 11 11 11 11 0 0 0 0 0 0 0 0 0 0]; assert(isequal(Matrix_Spiral(n),y_correct))

Assertion failed.

7   Fail
n = 17; y_correct =[11 11 11 11 11 11 11 11 11 11 11 11 11 11 11 11 11 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 11 0 0 11 11 11 11 11 11 11 11 11 11 11 11 11 0 11 0 0 11 0 0 0 0 0 0 0 0 0 0 0 11 0 11 0 0 11 0 11 11 11 11 11 11 11 11 11 0 11 0 11 0 0 11 0 11 0 0 0 0 0 0 0 11 0 11 0 11 0 0 11 0 11 0 11 11 11 11 11 0 11 0 11 0 11 0 0 11 0 11 0 11 0 0 0 11 0 11 0 11 0 11 0 0 11 0 11 0 11 0 11 0 11 0 11 0 11 0 11 0 0 11 0 11 0 11 0 11 11 11 0 11 0 11 0 11 0 0 11 0 11 0 11 0 0 0 0 0 11 0 11 0 11 0 0 11 0 11 0 11 11 11 11 11 11 11 0 11 0 11 0 0 11 0 11 0 0 0 0 0 0 0 0 0 11 0 11 0 0 11 0 11 11 11 11 11 11 11 11 11 11 11 0 11 0 0 11 0 0 0 0 0 0 0 0 0 0 0 0 0 11 0 0 11 11 11 11 11 11 11 11 11 11 11 11 11 11 11 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]; assert(isequal(Matrix_Spiral(n),y_correct))

Assertion failed.

Suggested Problems

More from this Author1