bool
bool
Function
Convert the value to a Boolean value according to BT truth rules.
Syntax
bool(value)
Parameters
| Parameters | Type | Required | Default value | Description |
|---|---|---|---|---|
| value | Any | No | None | The value to convert. |
Return value
| Type | Description |
|---|---|
| Bool | Returns the converted Boolean value. |
Example
result = bool('BT') // Output: true print result
Notes
- Null, Empty, 0, 0.0, false, empty string, empty array, and empty object are false.