Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
filetext = fileread('UpperMat.m');
assert(isempty(strfind(filetext, 'triu')),'triu() forbidden')
|
2 | Pass |
x = [2 4 -2; 4 -2 6; 6 -4 2] ;
y_correct = [2 4 -2; 0 -10 10; 0 0 -8];
assert(isequal(UpperMat(x),y_correct))
|
3 | Pass |
x = [15 7 5; 2 4 6; 0 9 10] ;
y_correct = [15 7 5; 0 46/15 16/3; 0 0 -130/23];
assert(abs(sum(sum(UpperMat(x)-y_correct)))<0.01)
|
3968 Solvers
Sum all integers from 1 to 2^n
8420 Solvers
Make one big string out of two smaller strings
1149 Solvers
320 Solvers
516 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!