数组splice:删除后,后面的元素自动填补到前面 arr.splice(index, 1); 例子://arr=[‘a’,‘b’,‘c’,‘d’] arr.splice(1, 1);//结果arr=[‘a’,‘c’,‘d’](下标1开始,删除1个) json delete itemIdArray[“要删除的key”]; var arrjson = {“a”:“a”,“b”,“b”}; 执行:delete itemIdArray[“a”]; 结果:arrjson == {“b”,“b”};