Conditional statement, which is a kind of statement that chooses to execute according to the condition in the program, the difficulty lies in how to abstract the condition accurately in the actual use of such statement. For example, to implement the
PL/SQL script language value assignment statement syntax table and record comply with the type usage, select the statement if else usage anonymous block (1), assign value statement syntax PL/SQL values use: = "=" some rules need to be observed in
If ... Then ... Else statementConditionally executes a set of statements based on the value of an expression.
If condition Then statements [Else elsestatements]
Or, use block-form syntax:
If condition Then[Statements][ElseIf condition-n
First, If...else statement
If...else statement
Executes a piece of code when the condition is set, and executes another piece of code when the condition is not established
Grammar:
1. Simple condition
if (condition) {
......
}
else{
......
First, If...else statement
If...else statement
Executes a piece of code when the condition is set, and executes another piece of code when the condition is not established
Grammar:
1. Simple condition
if (condition) {......}else{......}
Cases
Objective
Process Control statement:
In the process of executing a program, the order of execution of each statement has a direct effect on the result of the program. That is to say, the process of the program has a direct impact on the running
How to Use the if... else statement in Lua
This article mainly introduces how to use the if... else statement in Lua. It is the basic knowledge of Lua beginners. For more information, see
The if statement can be followed by an optional else
1, if statement
An If statement is an important feature in most languages, and it executes the program segment according to the conditions. PHP's If statement is similar to C:
if (expr)
Statement
As discussed in an expression, expr is computed
Document directory
Instance 1
Instance 2
Syntax:
Instance
Syntax:
Instance:
The Condition Statement in Javascript is used to complete the action under different conditions.Instance
If statement
How to compile an if statement.
This article mainly introduces the usage of the IF ... else statement in Lua, which is the basic knowledge in Lua's introductory learning, and can be consulted by a friend.
An If statement can be followed by an optional else statement, when the
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.