📅  最后修改于: 2022-03-11 15:02:17.051000             🧑  作者: Mango
/*
* On the left-hand side, you decide which values to unpack from the right-hand
* side source variable.
*
* This was introduced in ES6
*/
const x = [1, 2, 3, 4, 5]
const [a, b] = x
console.log(a) // prints out: 1
console.log(b) // prints out: 2