"be consistent" | |
PerlMonks |
Re: incorrect outputby merlyn (Sage) |
on Feb 05, 2005 at 13:02 UTC ( [id://428310]=note: print w/replies, xml ) | Need Help?? |
That's the correct output. You may be misunderstanding this line:
This line creates an anonymous hash by taking pairs of elements to create individual hash elements. With warnings enabled, you'd have also have been notified that the element "5" has no pair to take with it, so the hash is also improperly specified. Then the reference to this new anonymous hash becomes the sole element of the array @a. Perhaps you wanted:
-- Randal L. Schwartz, Perl hacker
In Section
Tutorials
|
|