getRondom (arr, len) {
      var out = []

      while (len) {
        var index = Math.floor(Math.random() * arr.length)

        if (out.includes(index)) {

        } else {
          arr.splice(index, 1)
          out = out.concat(index)
          len--
        }
      }

      return out
    }

  

相关文章:

  • 2021-10-08
  • 2022-12-23
  • 2022-12-23
  • 2022-01-26
  • 2021-10-09
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-11-10
  • 2021-06-16
相关资源
相似解决方案