Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
x=[1 2 3];
y=[4 5 6];
z_correct = [5 6 7;6 7 8;7 8 9]
assert(isequal(addmat(x,y),z_correct))
z_correct =
5 6 7
6 7 8
7 8 9
ans =
[]
|
2 | Pass |
x=[10 20 30 40];
y=[-10 -20 -30 -40];
z_correct = [0 10 20 30;-10 0 10 20;-20 -10 0 10;-30 -20 -10 0]
assert(isequal(addmat(x,y),z_correct))
z_correct =
0 10 20 30
-10 0 10 20
-20 -10 0 10
-30 -20 -10 0
ans =
[]
|
1421 Solvers
546 Solvers
413 Solvers
343 Solvers
273 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!