問題:
In Perl (and other languages) a conditional ternary operator can be expressed like this:在 Perl(和其他語言)中,條件三元運算符可以這樣表示:
my $foo = $bar == $buz ? $cat : $dog;
Is there a similar operator in VB.NET? VB.NET 中是否有類似的運算符?
解決方案:
參考一: https://stackoom.com/question/2PxH參考二: Is there a conditional ternary operator in VB.NET?