![]() |
|
good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re^2: Ternary Quizical behaviour?by Eily (Monsignor) |
on Jul 10, 2020 at 12:40 UTC ( #11119140=note: print w/replies, xml ) | Need Help?? |
But since the default is 0, this should mitigate the need for definedI don't understand what you mean here. As far as I know, defined $test{'a'} ? $test{'a'} : 0 and $test{'a'} // 0 are strictly equivalent. Beyond that ++ for the answer, the use of // here is a clear winner :)
In Section
Seekers of Perl Wisdom
|
|