跳到主要内容

随机算法

问题​

实现一个数组洗牌函数 shuffle​

const shuffle = (list) => list.sort((x, y) => Math.random() - 0.5)
#