pop ( seq -- elt )
Factor handbook > The language > Collections > Sequence operations > Treating sequences as stacks

Prev:push-all ( src dst -- )
Next:pop* ( seq -- )


Vocabulary
sequences

Inputs and outputs
seqa resizable mutable sequence
eltan object


Word description
Outputs the last element after removing it and shortening the sequence.

Side effects
Modifies seq

Errors
Throws an error if the sequence is empty.

See also
push, push-either, push-if, pop*, prefix, suffix, suffix!

Definition