Neighboring functions:

umask
undef
unlink
unpack
unshift
untie
use
utime
values

unshift

Examples:
unshift-ARRAY,LIST
Description:

Does the opposite of a shift. Or the opposite of a push, depending on how you look at it. Prepends list to the front of the array, and returns the new number of elements in the array.

    unshift(@ARGV, '-e') unless $ARGV[0] =~ /^-/;  

Note the LIST is prepended whole, not one element at a time, so the prepended elements stay in the same order. Use reverse to do the reverse.


No comments have been provided yet. Please feel free to add one.
Post a comment
Function examples and description are legal property of their respective authors. Comments belong to their posters.