Vb.net-decision-making
提供:Dev Guides
VB.Net-意思決定
意思決定構造では、プログラマーが、プログラムによって評価またはテストされる1つ以上の条件を、条件が真であると判断された場合に実行されるステートメント、およびオプションで条件が実行された場合に実行される他のステートメントとともに指定する必要があります偽と判断されます。
以下は、ほとんどのプログラミング言語で見られる典型的な意思決定構造の一般的な形式です-
VB.Netは、以下のタイプの意思決定ステートメントを提供します。 詳細を確認するには、次のリンクをクリックしてください。
Statement | Description |
---|---|
If … Then statement | An *If…Then statement *consists of a boolean expression followed by one or more statements. |
If…Then…Else statement | An* If…Then statement can be followed by an optional Else statement*, which executes when the boolean expression is false. |
nested If statements | You can use one If *or Else if statement inside another If or Else if *statement(s). |
Select Case statement | A* Select Case *statement allows a variable to be tested for equality against a list of values. |
nested Select Case statements | You can use one* select case statement inside another select case* statement(s). |