Cody

Solution 2026582

Submitted on 18 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
x = [1 2 4; 6 0 3; 4 1 5]; y_correct = [6 2 5; 4 1 4]; assert(isequal(your_fcn_name(x),y_correct))

y = 1 6 y = 1 2 6 0 y = 1 2 4 6 0 3

Assertion failed.

2   Pass
x = ones(3); y_correct = ones(2,3); assert(isequal(your_fcn_name(x),y_correct))

y = 1 1 y = 1 1 1 1 y = 1 1 1 1 1 1

3   Fail
x = eye(4); y_correct = [ones(1,4); zeros(1,4)]; assert(isequal(your_fcn_name(x),y_correct))

y = 1 0 y = 1 0 0 1 y = 1 0 0 0 1 0 y = 1 0 0 0 0 1 0 0

Assertion failed.

4   Fail
x = [1:5; 6:10; 11:15; 16:20; 21:25]; y_correct = [21:25; 16:20]; assert(isequal(your_fcn_name(x),y_correct))

y = 1 6 y = 1 2 6 7 y = 1 2 3 6 7 8 y = 1 2 3 4 6 7 8 9 y = 1 2 3 4 5 6 7 8 9 10

Assertion failed.

5   Fail
x = [1 5 7 3 47 2 3; 6 7 1 5 23 1 47; 7 1 3 2 68 4 11]; y_correct = [7 7 7 5 68 4 47; 6 5 3 3 47 2 11]; assert(isequal(your_fcn_name(x),y_correct))

y = 1 6 y = 1 5 6 7 y = 1 5 7 6 7 1 y = 1 5 7 3 6 7 1 5 y = 1 5 7 3 47 6 7 1 5 23 y = 1 5 7 3 47 2 6 7 1 5 23 1 y = 1 5 7 3 47 2 3 6 7 1 5 23 1 47

Assertion failed.