摘要: var arr = [1,2,3,4,5,6,7,8,9,10]; arr.sort(()=>{ return Math.random() - 0.5;}) //这种当然简单点啦 阅读全文
posted @ 2018-12-24 10:46 疾风_剑豪 阅读(146) 评论(0) 推荐(0) 编辑
摘要: function mm(num) { return num && num .toString() .replace(/(\d)(?=(\d{3})+\.)/g, function($0, $1) { return $1 + ","; }); } console.log(mm(4152465465456.454)); ... 阅读全文
posted @ 2018-12-24 10:41 疾风_剑豪 阅读(203) 评论(0) 推荐(0) 编辑