values: [7, 6, 5, 4, 3, 2, 1, 0]
+ indices(0-based): {6, 1, 7}
+Where the correct result would be:
+[7, 0, 5, 4, 3, 2, 1, 6]
.
+sortDisjoint
should be a function.
+ testString: assert(typeof sortDisjoint == 'function', 'sortDisjoint
should be a function.');
+ - text: sortDisjoint([7, 6, 5, 4, 3, 2, 1, 0], [6, 1, 7])
should return a array.
+ testString: assert(Array.isArray(sortDisjoint([7, 6, 5, 4, 3, 2, 1, 0], [6, 1, 7])), 'sortDisjoint([7, 6, 5, 4, 3, 2, 1, 0], [6, 1, 7])
should return a array.');
+ - text: sortDisjoint([7, 6, 5, 4, 3, 2, 1, 0], [6, 1, 7])
should return [7, 0, 5, 4, 3, 2, 1, 6]
.
+ testString: assert.deepEqual(sortDisjoint([7, 6, 5, 4, 3, 2, 1, 0], [6, 1, 7]), [7, 0, 5, 4, 3, 2, 1, 6], 'sortDisjoint([7, 6, 5, 4, 3, 2, 1, 0], [6, 1, 7])
should return [7, 0, 5, 4, 3, 2, 1, 6]
.');
+ - text: sortDisjoint([7, 6, 5, 4, 3, 2, 1, 0], [1, 2, 5, 6])
should return [7, 1, 2, 4, 3, 5, 6, 0]
.
+ testString: assert.deepEqual(sortDisjoint([7, 6, 5, 4, 3, 2, 1, 0], [1, 2, 5, 6]), [7, 1, 2, 4, 3, 5, 6, 0], 'sortDisjoint([7, 6, 5, 4, 3, 2, 1, 0], [1, 2, 5, 6])
should return [7, 1, 2, 4, 3, 5, 6, 0]
.');
+ - text: sortDisjoint([8, 7, 6, 5, 4, 3, 2, 1], [6, 1, 7])
should return [8, 1, 6, 5, 4, 3, 2, 7]
.
+ testString: assert.deepEqual(sortDisjoint([8, 7, 6, 5, 4, 3, 2, 1], [6, 1, 7]), [8, 1, 6, 5, 4, 3, 2, 7], 'sortDisjoint([8, 7, 6, 5, 4, 3, 2, 1], [6, 1, 7])
should return [8, 1, 6, 5, 4, 3, 2, 7]
.');
+ - text: sortDisjoint([8, 7, 6, 5, 4, 3, 2, 1], [1, 3, 5, 6])
should return [8, 2, 6, 3, 4, 5, 7, 1]
.
+ testString: assert.deepEqual(sortDisjoint([8, 7, 6, 5, 4, 3, 2, 1], [1, 3, 5, 6]), [8, 2, 6, 3, 4, 5, 7, 1], 'sortDisjoint([8, 7, 6, 5, 4, 3, 2, 1], [1, 3, 5, 6])
should return [8, 2, 6, 3, 4, 5, 7, 1]
.');
+ - text: sortDisjoint([6, 1, 7, 1, 3, 5, 6], [6, 1, 5, 4])
should return [6, 1, 7, 1, 3, 5, 6]
.
+ testString: assert.deepEqual(sortDisjoint([6, 1, 7, 1, 3, 5, 6], [6, 1, 5, 4]), [6, 1, 7, 1, 3, 5, 6],'sortDisjoint([6, 1, 7, 1, 3, 5, 6], [6, 1, 5, 4])
should return [6, 1, 7, 1, 3, 5, 6]
.');
+```
+
+