default (in switch)
This default keyword executes the else condition statement.
Purpose
This keyword is used in the switch statement to execute the else condition.
Context
switch statements
Syntax
switch (expression)
case value1:
{ruleflowStatement}
...
default:
{ruleflowStatement}
Description
The switch statement is a conditional ruleflow statement. The integer expression is evaluated. If a value of the case block is equal to the evaluated expression, the corresponding statement block is executed. If no block with the requested value is found, the default block is executed.