const array = [1, 2, 3, 4] //remove the first element of the array array.shift() //add an element to the beginning of the array array.unshift() //remove the last element in an array array.pop() //add an element to the end of the array array.push()
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter