📜  javascript atualize array - Javascript代码示例

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

代码示例1
let yourArray = [1,2,3,4,5];
// if you want to change " 3 " for " 6 " you must count the indexs
// item | 1 2 3 4 5
// index| 0 1 2 3 4
yourArray[2] = 6
// yourArray -> [1,2,6,4,5]