Questions about this topic? Sign up to ask in the talk tab.
Difference between revisions of "Perl/Basics/Variables and Data Types/Helper Functions/Push"
From NetSec
AlizaLorenzo (Talk | contribs) (Created page with "The '''push()''' function is used to append an element or elements to the end of an array, similar to the push instruction in assembly and treats...") |
Chantal21I (Talk | contribs) m (moved Perl/Basics/Helper Functions/Push to Perl/Basics/Variables and Data Types/Helper Functions/Push) |
(No difference)
|
Latest revision as of 01:18, 19 July 2012
The push() function is used to append an element or elements to the end of an array, similar to the push instruction in assembly and treats the array like a stack.
my @array; push(@array,'element one'); push(@array,('element two','element three')); |
$array[$#array] = "new element";