3 ms·
Why not just do two tests: check if every element is present exactly once or some variation of it depending on what is considered unique; do the `for i in (0..a
by zerof1l 4y ago
Why not just do two tests: check if every element is present exactly once or some variation of it depending on what is considered unique; do the `for i in (0..array.size-2) { assert array[i] <= array[i+1] }` as was suggested. That way you don't need to test against a known good sorting algorithm.