Cody

Solution 936655

Submitted on 15 Aug 2016 by Martin C.
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Pass
v = 1:6; n=3 vNew = 4:6; assert(isequal(returnGreaterThan(v,n),vNew))

n = 3 vNew = 1 2 3 4 5 6 vNew = 1 2 4 5 6 vNew = 1 4 5 6 vNew = 4 5 6

2   Pass
v = [10:-2:-10]; n=0 vNew = [10 8 6 4 2]; assert(isequal(returnGreaterThan(v,n),vNew))

n = 0 vNew = 10 8 6 4 2 0 -2 -4 -6 -8 -10 vNew = 10 8 6 4 2 0 -2 -4 -6 -8 vNew = 10 8 6 4 2 0 -2 -4 -6 vNew = 10 8 6 4 2 0 -2 -4 vNew = 10 8 6 4 2 0 -2 vNew = 10 8 6 4 2 0 vNew = 10 8 6 4 2

3   Pass
v = [4 pi -2 0 -17000 8 91]; n=3 vNew = [4 pi 8 91]; assert(isequal(returnGreaterThan(v,n),vNew))

n = 3 vNew = 1.0e+04 * 0.0004 0.0003 -0.0002 0 -1.7000 0.0008 0.0091 vNew = 4.0000 3.1416 -2.0000 0 8.0000 91.0000 vNew = 4.0000 3.1416 -2.0000 8.0000 91.0000 vNew = 4.0000 3.1416 8.0000 91.0000