/
githubmirror
/
atom
Обзор
Документация
Войти
/
githubmirror
/
atom
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
spec/fixtures/sample.js
13 строк
408 B
Corey Johnson & Nathan Sobo
Get spec suite running (lots of failures)
28 авг 2012, 02:36
28 авг 2012, 02:36
12b06dd
Код
Авторство
О чём код?
var quicksort = function () { var sort = function(items) { if (items.length <= 1) return items; var pivot = items.shift(), current, left = [], right = []; while(items.length > 0) { current = items.shift(); current < pivot ? left.push(current) : right.push(current); } return sort(left).concat(pivot).concat(sort(right)); }; return sort(Array.apply(this, arguments)); };