http://qs321.pair.com?node_id=11119140


in reply to Re: Ternary Quizical behaviour?
in thread Ternary Quizical behaviour?

But since the default is 0, this should mitigate the need for defined
I 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 :)

Replies are listed 'Best First'.
Re^3: Ternary Quizical behaviour?
by perlfan (Vicar) on Jul 10, 2020 at 20:44 UTC
    I just said what you made clear, but I did so in a very awkward way. Thanks for the ++! :)