Cody

Solution 1894165

Submitted on 7 Aug 2019 by Michael Tadros
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
n = 10; flagSame = isequal(makeRandomOrdering(n), makeRandomOrdering(n)); flagAllUsed = isequal([1:n],sort(makeRandomOrdering(n))); assert(~flagSame & flagAllUsed)

vec = 1 7 5 2 9 6 4 10 8 3 vec = 7 9 8 2 5 1 4 3 6 10 vec = 10 2 6 8 4 9 3 1 5 7