Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

perlfunc:push

by gods
on Aug 24, 1999 at 22:42 UTC ( #251=perlfunc: print w/replies, xml ) Need Help??

push

See the current Perl documentation for push.

Here is our local, out-dated (pre-5.6) version:


push - append one or more elements to an array



push ARRAY,LIST



Treats ARRAY as a stack, and pushes the values of LIST onto the end of ARRAY. The length of ARRAY increases by the length of LIST. Has the same effect as

    for $value (LIST) {
        $ARRAY[++$#ARRAY] = $value;
    }

but is more efficient. Returns the new number of elements in the array.


Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
[marioroy]: Is List::Util::XS a core Perl module?
[stevieb]: corelist List::Util::XS says "List::Util::XS was first released with perl v5.10.1"
[stevieb]: so yes, since v5.10.1 :)
[MidLifeXis]: According to [metaperl:// corelist], Perl 5.10.1
Lady_Aleena blurbles. One of her favorite modiles is now in "maintenance mode" in favor of a new fangled module.
[MidLifeXis]: D'oh. Slow out of the gate.
[marioroy]: Thanks stevieb, MidLifeXis.
[MidLifeXis]: corelist Typo. Wow. Time to go, fingers are malfunctioning.

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (10)
As of 2017-05-24 17:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?