使用单等于号来向变量赋值,而不是像在前一个条件中那样使用双等于号 (==) 来比较值。
Use the single equal sign to assign a value to a variable, unlike the double equal sign (==), as in the previous condition, which compare the values.
避免在if和while语句的条件部分进行赋值。
Avoid doing assignments in the condition part of if and while statements.
对用户来说,最棒的是他们不再局限于简单的赋值;用Lua表达的配置文件可以有注释、条件等。
What makes this excellent for users is that they are no longer restricted to simple assignments of values; configuration files expressed as Lua can have comments, conditionals, and more.
这条语句仅当用户居住在康涅狄格州(relevant条件)时,才将TaxRate (ref)赋值为康涅狄格州税率(calculate)。
This statement assigns TaxRate (ref) to the Connecticut tax rate (calculate) only if the user lives in Connecticut (relevant condition).
一般来讲,你可以用条件表达式来替换掉条件语句,无论这些语句的分支是返回语句或者是赋值语句。
In general, you can replace a conditional statement with a conditional expression if both branches contain simple expressions that are either returned or assigned to the same variable.
通过不对只出现在可观无关条件中的变量赋值,保证电路的控制唯一性。
By making no decision on variables which only appear in the ODC conditions, the control uniqueness of the circuit is guaranteed.
避免在条件中直接调用返回布尔值的函数。把返回值赋值给一个局部变量来使用。
Avoid function calls in Boolean conditional statements. Assign into local variables and check on them.
本文给出了有单位元的弱准素环的一个新刻划并给出了弱准素整环是拟赋值环或赋值环的条件。
We give a new characterization of weakly primary rings with identity and conditions that a weakly primary domain is a valuation ring or quasi-valuation ring.
本文给出了有单位元的弱准素环的一个新刻划并给出了弱准素整环是拟赋值环或赋值环的条件。
We give a new characterization of weakly primary rings with identity and conditions that a weakly primary domain is a valuation ring or quasi-valuation ring.
应用推荐