JavaScript - Delete Element from the Beginning of JS Array
These are the following ways to delete elements from JavaScript arrays: 1. Using shift() method - Mostly UsedThe shift() method removes the first element from the array and adjusts its length. [GFGTABS] JavaScript const a = [1, 2, 3, 4]; // Remove the first element a.shift(); console.log(a); [/GFGTA