Cody

# Problem 44415. Remove the first, third and fifth rows of a matrix

Solution 1908848

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

x = 2 4 6 1 2 3 4 5 6 1 2 3 4 5 6

Output argument "y" (and maybe others) not assigned during call to "deleteThreeRows". Error in Test1 (line 10) assert(isequal(deleteThreeRows(x),y_correct))

2   Fail
x = (1:5)'; y_correct = [2;4]; assert(isequal(deleteThreeRows(x),y_correct))

x = 2 4

Output argument "y" (and maybe others) not assigned during call to "deleteThreeRows". Error in Test2 (line 3) assert(isequal(deleteThreeRows(x),y_correct))

3   Fail
x = ones(8); y_correct = ones(5, 8); assert(isequal(deleteThreeRows(x),y_correct))

x = Columns 1 through 30 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 Columns 31 through 60 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 Columns 61 through 63 1 1 1

Output argument "y" (and maybe others) not assigned during call to "deleteThreeRows". Error in Test3 (line 3) assert(isequal(deleteThreeRows(x),y_correct))

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!