SOURCE

let arr = [1,2,3,4,5,6]
let arr1 = [7,8,9,10]
let arr3 = arr.concat(arr1)
console.log(arr3)

let arr4 = arr.splice(0,3,11)
console.log(arr)
console.log(arr4)

let arr5 = arr1.slice(0,2)
console.log(arr5)
console.log(arr1)

var str = "abcadfjsaoflpsa"
var index = str.indexof("a")
while(index === -1){
    console.log(index)
}
console 命令行工具 X clear

                    
>
console