The pop() method is similar to the shift() method, but the difference is that the Shift method works at the array’s start. The pop() method takes the last element off of the given array and returns it. The array on which it is called is then altered.
Example:
var cloths = ["Shirt", "Pant", "TShirt"]; cloths.pop(); //Now cloth becomes Shirt,Pant