Skip to content
Subhajit Sahu edited this page May 19, 2020 · 18 revisions

Removes last value. 🏃 📼 📦 🌔 📒

Alternatives: [pop], [pop$].
Similar: [push], [pop], [shift], [unshift].

array.pop$(x);
// x: an array (updated)
// --> value
const array = require('extra-array');

var x = [1, 2, 3];
array.pop(x);
// [ 1, 2 ]

x;
// [ 1, 2 ]

var x = [1, 2, 3, 4];
array.pop(x);
// [ 1, 2, 3 ]

references

Clone this wiki locally