条件运算符的优先级比按位运算符的优先级低。
The conditional operator has lower precedence than bitwise operators.
按位运算符强制。
然而,按位运算符和移位运算符永远不会导致溢出。
However, bitwise operators and shift operators never cause overflow.
按位运算符会对两个自变量中对应的位执行布尔代数,并最终生成一个结果。
Bitwise operators perform Boolean algebra on the corresponding bits in the two arguments to produce the result.
如果被测试表达式中应当包含按位或运算符,则应当在条件表达式的两侧加上括号。
If the tested expression should contain the bitwise-or operator, then parentheses should be added around the conditional-expression.
按位或向结果表达式添加位,而按位与只选择两个运算符之间相同的位。
Bitwise-or adds bits to the resulting expression, whereas bitwise-and selects only those bits in common between its two operators.
按位或向结果表达式添加位,而按位与只选择两个运算符之间相同的位。
Bitwise-or adds bits to the resulting expression, whereas bitwise-and selects only those bits in common between its two operators.
应用推荐