Clear questions and runnable code get the best and fastest answer |
|
PerlMonks |
Re: Array mysteriously growingby swkronenfeld (Hermit) |
on Mar 09, 2006 at 15:17 UTC ( [id://535408]=note: print w/replies, xml ) | Need Help?? |
With your first method The if is evaluated first, comes out to false, and the $ordered_list->[($i+1)]->[0] is never evaluated. With your second method, the $ordered_list->[($i+1)]->[0] is evaluated first. Even if this value does not exist, it is autovivified.
In Section
Seekers of Perl Wisdom
|
|