Answers for "javascript remove 1st element from array"

20

javascript remove first element from array

var arr = [1, 2, 3, 4]; 
var theRemovedElement = arr.shift(); // theRemovedElement == 1
console.log(arr); // [2, 3, 4]
Posted by: Guest on July-10-2020

Code answers related to "javascript remove 1st element from array"

Code answers related to "Javascript"

Browse Popular Code Answers by Language