Difference between revisions of "True"
Jump to navigation
Jump to search
m (→Examples) |
|||
(5 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
A logical (Boolean) value. Logical values are used in logical (Boolean) expressions and for true/false inputs. | A logical (Boolean) value. Logical values are used in logical (Boolean) expressions and for true/false inputs. | ||
− | + | == Usage == | |
− | + | <syntaxhighlight>True</syntaxhighlight> | |
− | == | + | == Notes == |
− | [[ | + | * Also see [[False]] for the logical false Boolean value. |
+ | * See [[And]] and [[Or]] for combining true/false expressions in one statement. | ||
− | + | == Examples == | |
+ | <syntaxhighlight>True Or False</syntaxhighlight> | ||
+ | Will return a value of True. | ||
− | + | <syntaxhighlight> | |
+ | 2 = 2</syntaxhighlight> | ||
+ | will return a value of True | ||
− | + | Declare ''LogicalVar'' as a true/false variable with the initial value of true: | |
− | + | <syntaxhighlight>Variable: LogicalVar(True);</syntaxhighlight> | |
− | + | Declare ''Overnight'' as a true/false input with the default value of true: | |
+ | <syntaxhighlight>Input: Overnight(True);</syntaxhighlight> | ||
[[Category:Comparisons and Loops]] | [[Category:Comparisons and Loops]] |
Latest revision as of 11:27, 19 February 2012
A logical (Boolean) value. Logical values are used in logical (Boolean) expressions and for true/false inputs.
Usage
True
Notes
- Also see False for the logical false Boolean value.
- See And and Or for combining true/false expressions in one statement.
Examples
True Or False
Will return a value of True.
2 = 2
will return a value of True
Declare LogicalVar as a true/false variable with the initial value of true:
Variable: LogicalVar(True);
Declare Overnight as a true/false input with the default value of true:
Input: Overnight(True);