delete a variable in an array code example
Example 1: how to delete an element from an array
var array = [123, "yee", true];
array.pop(index);
Example 2: how to remove a variable from an array javascript
let colors = ["red","blue","car","green"];
//remove car from the colors array
colors.splice(color[2]); // colors = ["red","blue","green"]