JS數組隨機排序

隨機排序 let arr = [1,2,3,5,6,12,31,4]; arr.sort(function(){return Math.random() - 0.5}); 注意:此處排序會改變原數組web
相關文章
相關標籤/搜索