reverse() 會把陣列元素反向排列,並直接修改原陣列。
var arr = new Array(1, 2, 3); arr.reverse(); // 3, 2, 1
它不是排序,只是把原有順序反過來。