Test  Status  Code Input and Output 

1  Fail 
x = 25;
y=sumOfSqr(x);
v=y(1)^2 + y(2)^2;
assert(isequal(x,v))
assert(round(y(1))==y(1))
assert(round(y(2))==y(2))

2  Fail 
x = 41;
y=sumOfSqr(x);
v=y(1)^2 + y(2)^2;
assert(isequal(x,v))
assert(round(y(1))==y(1))
assert(round(y(2))==y(2))

3  Fail 
x = 7;
y=sumOfSqr(x);
assert(isempty(y));

4  Fail 
x = 391250;
y=sumOfSqr(x);
v=y(1)^2 + y(2)^2;
assert(isequal(x,v))
assert(round(y(1))==y(1))
assert(round(y(2))==y(2))

5  Fail 
x = 288;
y=sumOfSqr(x);
v=y(1)^2 + y(2)^2;
assert(isequal(x,v))
assert(round(y(1))==y(1))
assert(round(y(2))==y(2))

6  Fail 
x = 1;
y=sumOfSqr(x);
v=y(1)^2 + y(2)^2;
assert(isequal(x,v))
assert(round(y(1))==y(1))
assert(round(y(2))==y(2))

6280 Solvers
351 Solvers
Similar Triangles  find the height of the tree
203 Solvers
284 Solvers
69 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!