var data = [ "X", "Y", "Z" ];data.shift(); What is the output of this code?
The shift() method removes the first element and returns that removed element from an array. This method changes the length of the array.
Remove the first item of an array:
var courses = ["HTML", "SQL", "CSS", "Oracle"]; fruits.shift();
The above code output will be as below:
SQL, CSS, Oracle
Pick the difference between the alert box and the confirmation box?