This solution is outdated. To rescore this solution, sign in.
Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
m = 3; n = 4;
Z_correct = [1 2 3 4; 5 6 7 8; 9 10 11 12];
assert(isequal(your_fcn_name(m,n),Z_correct))
Z =
1 2 3 4
5 6 7 8
9 10 11 12
|
2 | Pass |
m = 2; n = 5;
Z_correct = [1 2 3 4 5; 6 7 8 9 10];
assert(isequal(your_fcn_name(m,n),Z_correct))
Z =
1 2 3 4 5
6 7 8 9 10
|
3 | Pass |
m = 1; n = 8;
Z_correct = [1 2 3 4 5 6 7 8];
assert(isequal(your_fcn_name(m,n),Z_correct))
Z =
1 2 3 4 5 6 7 8
|
4 | Pass |
m = 5; n = 1;
Z_correct = [1 2 3 4 5]';
assert(isequal(your_fcn_name(m,n),Z_correct))
Z =
1
2
3
4
5
|
5 | Pass |
filetext = fileread('your_fcn_name.m');
assert(isempty(strfind(filetext, 'for')),'for forbidden')
assert(isempty(strfind(filetext, 'while')),'while forbidden')
|
386 Solvers
Rotate input square matrix 90 degrees CCW without rot90
380 Solvers
272 Solvers
Find the area of the four walls
202 Solvers
Tick. Tock. Tick. Tock. Tick. Tock. Tick. Tock. Tick. Tock.
761 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!