三元运算符 meaning in Chinese
ternary if-else operator
Examples
- The assignment operators and the tertiary operator
赋值运算符和三元运算符( - Takes three operands and is the sole tertiary operator in c
接受三个操作数,是c #中唯一的三元运算符。 - Although c ( where this operator originated ) prides itself on being a terse language , and the ternary operator might have been introduced partly for efficiency , you should be somewhat wary of using it on an everyday basis ? it ' s easy to produce unreadable code
尽管c引以为傲的就是它是一种简练的语言,而且三元运算符的引入多半就是为了体现这种高效率的编程,但假若您打算频繁用它,还是要先多作一些思量? ?它很容易就会产生可读性极差的代码。