QUICK Jow Forums

QUICK Jow Forums

GIVEN AN ARBITRARY ARRAY OF INTEGERS, SORT IT SO THAT ALL THE NINES ARE AT THE END OF THE LIST OR THIS BIRD WILL STAB YOU

e.g.
[1,9,7,4,9,3,2,6,9]
to
[1, 7, 4, 3, 2, 6, 9, 9, 9]

Attached: 34A6DBE700000578-3611571-A_crow_snatched_a_knife_from_the_scene_of_a_shooting_in_Canada_a-m-37_14642 (634x635, 181K)

Other urls found in this thread:

gkoberger.github.io/stacksort/
pastebin.com/LDDhWrKs
pastebin.com/mx91wuT1
pastebin.com/fckkPJWZ
twitter.com/SFWRedditVideos

im not doing your homework for you, faggot.

Attached: 1467151892792.jpg (300x300, 10K)

You will drop out your course is over and will have nothing to show for it but debt

Because you can't

Waiting for the Haskell one liner chad to appear

Array.prototype.sleepSort = function(callback) {
const res = [];
for (let n of this)
setTimeout(() => {
res.push(n);
if (this.length === res.length)
callback(res);
}, n + 1);
return res;
};

[1,9,7,4,9,3,2,6,9].sleepSort(console.log);

arr.filter(item => item !== 9).concat(arr.filter(item => item === 9)

Is it a custom now to post homework questions in this format?

Use stacksort: gkoberger.github.io/stacksort/

arr.sort()

Or write a sort algo from Wikipedia