in reply to undef vs. $foo = 0
foreach $foo(@foo) { $bar = $some + $thing; } [download]
If $bar has a default value, set it to that value, otherwise undef.