Cody

# Problem 1422. frame of the matrix

Solution 2122779

Submitted on 9 Feb 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
x = eye(9); y = [1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1]; assert(isequal(external_frame(x),y))

A null assignment can have only one non-colon index. Error in external_frame (line 2) x([1 end],1:end)=[] Error in Test1 (line 9) assert(isequal(external_frame(x),y))

2   Fail
x = magic(7); y = [47 7 9 18 27 6 8 17 26 35 14 16 25 34 36 15 24 33 42 44 23 32 41 43 3]; assert(isequal(external_frame(x),y))

A null assignment can have only one non-colon index. Error in external_frame (line 2) x([1 end],1:end)=[] Error in Test2 (line 7) assert(isequal(external_frame(x),y))

3   Fail
x = ones(2,2); y = []; assert(isequal(external_frame(x),y))

A null assignment can have only one non-colon index. Error in external_frame (line 2) x([1 end],1:end)=[] Error in Test3 (line 3) assert(isequal(external_frame(x),y))

4   Fail
x = zeros(2,2); y = []; assert(isequal(external_frame(x),y))

A null assignment can have only one non-colon index. Error in external_frame (line 2) x([1 end],1:end)=[] Error in Test4 (line 3) assert(isequal(external_frame(x),y))

5   Fail
x = eye(3); y = 1; assert(isequal(external_frame(x),y))

A null assignment can have only one non-colon index. Error in external_frame (line 2) x([1 end],1:end)=[] Error in Test5 (line 3) assert(isequal(external_frame(x),y))

6   Fail
x = ones(6,8); y = ones(4,6); assert(isequal(external_frame(x),y))

A null assignment can have only one non-colon index. Error in external_frame (line 2) x([1 end],1:end)=[] Error in Test6 (line 3) assert(isequal(external_frame(x),y))

7   Fail
x = 1; y = []; assert(isequal(external_frame(x),y))

A null assignment can have only one non-colon index. Error in external_frame (line 2) x([1 end],1:end)=[] Error in Test7 (line 3) assert(isequal(external_frame(x),y))