Using .splice();
- When you use splice
you are modify/editing the array
- deleteCount
is how many indexes you want to remove
- itemN
is if you want to replace the index
with different content
*Syntax array.splice(start[, deleteCount[, item1[, item2[, ...]]]])
Using .slice();