किसी array में कहीं भी new element add(insert) या delete करने के लिए splice () method का use करते हैं .
<script> var a = ["Apple", "Mango", "Banana"]; a.splice(1,2, "Ram"); document.write(a); </script>
var a = ["Apple", "Mango", "Banana"]; a.splice(1,2, "Ram"); document.write(a);