Cody

# Problem 43288. N-plicate me

Solution 1926624

Submitted on 9 Sep 2019
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   Fail
x = [1 2 3 4 5] n = 4 y_correct = [1 1 1 1 2 2 2 2 3 3 3 3 4 4 4 4 5 5 5 5] assert(isequal(NplicateMe(x,n),y_correct))

x = 1 2 3 4 5 n = 4 y_correct = 1 1 1 1 2 2 2 2 3 3 3 3 4 4 4 4 5 5 5 5 y = 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 y = 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 y = 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 y = Columns 1 through 29 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 Columns 30 through 32 4 1 4 4 1 4 4 1 4 4 1 4 y = Columns 1 through 29 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 Columns 30 through 40 4 1 4 1 5 1 5 1 5 1 5 4 1 4 1 5 1 5 1 5 1 5 4 1 4 1 5 1 5 1 5 1 5 4 1 4 1 5 1 5 1 5 1 5

Assertion failed.

2   Fail
x = [10 7 8] n = 2 y_correct = [10 10 7 7 8 8] assert(isequal(NplicateMe(x,n),y_correct))

x = 10 7 8 n = 2 y_correct = 10 10 7 7 8 8 y = 1 10 1 10 1 10 1 10 y = 1 10 1 10 1 7 1 7 1 10 1 10 1 7 1 7 y = 1 10 1 10 1 7 1 7 1 8 1 8 1 10 1 10 1 7 1 7 1 8 1 8

Assertion failed.