📜  js 推送到数组的开头 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:01:09.992000             🧑  作者: Mango

代码示例3
var name = [ "john" ];
name.unshift( "charlie" );
name.unshift( "joseph", "Jane" );
console.log(name);

//Output will be
[" joseph "," Jane ", " charlie ", " john "]