Cody

# Problem 1820. 07 - Common functions and indexing 5

Solution 1813343

Submitted on 12 May 2019 by Zoltán Nagy
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
Ref = 1:20; Ref(2:2:20)=Ref(2:2:20)*-1; user = MyFunc(); assert(isequal(user,Ref))

lin = 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 lin = 1 -2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 lin = 1 -2 3 -4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 lin = 1 -2 3 -4 5 -6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 lin = 1 -2 3 -4 5 -6 7 -8 9 10 11 12 13 14 15 16 17 18 19 20 lin = 1 -2 3 -4 5 -6 7 -8 9 -10 11 12 13 14 15 16 17 18 19 20 lin = 1 -2 3 -4 5 -6 7 -8 9 -10 11 -12 13 14 15 16 17 18 19 20 lin = 1 -2 3 -4 5 -6 7 -8 9 -10 11 -12 13 -14 15 16 17 18 19 20 lin = 1 -2 3 -4 5 -6 7 -8 9 -10 11 -12 13 -14 15 -16 17 18 19 20 lin = 1 -2 3 -4 5 -6 7 -8 9 -10 11 -12 13 -14 15 -16 17 -18 19 20 lin = 1 -2 3 -4 5 -6 7 -8 9 -10 11 -12 13 -14 15 -16 17 -18 19 -20