Javascript array_pop

Is there a great trick for PHP array_pop()in Javascript?

Instead of any nullity, I will accept elegance and / or brevity.

+3
source share
2 answers
var foo = [1,2,3];
foo.pop();
+3
source

Javascript has a pop function: http://www.w3schools.com/jsref/jsref_pop.asp

+2
source

Source: https://habr.com/ru/post/1772595/


All Articles