Assignment
Syntax
The assignment statement assigns the value of an expression to a variable. The type of the expression must be compatible with the type of the variable.variable-identifier := {arithmetic-expression | boolean-expression}
- variable-identifier
-
Is an identifier for a previously declared variable.
Example
Assign an arithmetic expression to a variable.
percent_shipped := (quantity_shipped / quantity_in_stock) * 100;
Assign a Boolean expression to a variable.
no_item_supplied := item == 0;