docs: function flatten(array) {
    const result = [];
    for (let i = 0; i < array.length; i++) {
      if (isArray(array[i])) {
        for (let q = 0; q < array[i].length; q++) {
          result.push(array[i][q]);
        }
      } else {
        result.push(array[i]);
      }
    }
    return result
  }