+ 5
I want explanarion of this riddle
var MyNumbers = [ 3,6,11,5 ]; MyNumbers.sort(function(a,b) { return b - a; }); I kinda know what this is all about, but wondering whats values a and b here? whats going on with it
4 ответов
+ 6
Check the "Numeric Sort" section:
https://www.w3schools.com/js/js_array_sort.asp
+ 1
I think the array will be sorted in descending order.
0
I think the code is incomplete.
0
Abdurrahman it is completed, because this question appeared in Challenge