📅  最后修改于: 2022-03-11 15:02:37.844000             🧑  作者: Mango
function shuffle(array){
let new_arr = [] ;
while (new_arr.length < array.length ){
let random_item = array[Math.floor(Math.random()*(array.length))];
if(!new_arr.includes(random_item)){new_arr.push(random_item)}
}
return new_arr
}