Loading

DUPN


stack
Since v1.0.0
Available on all platforms
See also

The DUPN function duplicates the top N elements of the stack after having consumed N which is on the top of the stack when calling DUPN.

As the DUP function, DUPN duplicates the references of the N elements on the top of the stack, it doesn’t copy the elements. If you apply DUPN to a GTS you will have two references to the same GTS object on the stack.

If you want to make a deep copy of a GTS, i.e. if you want copy the content and not only the reference, you can use the CLONE function.

Signature

Examples

'foo' 'bar' 2 DUPN