Test | Status | Code Input and Output |
---|---|---|
1 | Pass |
for ii=1:100
x = rand;
clear y z;
try
y = check(x);
catch
z = 'error';
end
end
assert(isequal(y,x))
assert(isequal(exist('y','var'),1))
assert(isequal(exist('z','var'),0))
|
2 | Pass |
for ii=1:100
x = -rand;
clear y z;
try
y = check(x);
catch
z = 'error';
end
end
assert(isequal(z,'error'))
assert(isequal(exist('y','var'),0))
assert(isequal(exist('z','var'),1))
|
17124 Solvers
How long is the longest prime diagonal?
338 Solvers
Cell Counting: How Many Draws?
581 Solvers
284 Solvers
277 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!