Difference between revisions of "Boolean"
From SCAR Divi Manual
(5 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
+ | ==Availability== | ||
+ | SCAR Divi 3.00 > Current | ||
+ | |||
==Description== | ==Description== | ||
− | Boolean is a basic type which can hold only 2 values | + | Boolean is a basic type which can hold only 2 values: [[False]] (0) and [[True]] (1). Conditional code constructs use boolean values to determine what action to perform. |
==Example== | ==Example== | ||
Line 6: | Line 9: | ||
var | var | ||
Value: Boolean; | Value: Boolean; | ||
+ | |||
begin | begin | ||
Value := True; | Value := True; | ||
Line 14: | Line 18: | ||
end. | end. | ||
</source> | </source> | ||
+ | |||
+ | Output: | ||
+ | Value was equal to True | ||
+ | |||
+ | ==See Also== | ||
+ | *[[TBooleanArray]] | ||
+ | *[[T2DBooleanArray]] | ||
+ | *[[BoolToStr]] | ||
+ | *[[StrToBool]] | ||
+ | *[[StrToBoolDef]] | ||
[[Category:Types]] | [[Category:Types]] | ||
[[Category:Basic Types]] | [[Category:Basic Types]] |
Latest revision as of 22:51, 19 October 2011
Contents
Availability
SCAR Divi 3.00 > Current
Description
Boolean is a basic type which can hold only 2 values: False (0) and True (1). Conditional code constructs use boolean values to determine what action to perform.
Example
var Value: Boolean; begin Value := True; if Value = True then WriteLn('Value was equal to True') else WriteLn('Value was equal to False'); end.
Output:
Value was equal to True