js调整数组某些元素到指定位置顺序_JS Array.reverse 将数组元素颠倒顺序
//JS Array.reverse 将数组元素颠倒顺序//在JavaScript中,Array对象的reverse()方法将颠倒(反转)数组中元素的顺序。arr.reverse()在原数组上实现这一功能,即,reverse()会改变原数组。//例1:var arr = ["f","e","i","e","s","o","f","t"];document.writeln(arr.join()); ...
复制链接