Berserk Docs
Scalar FunctionsType Functions

tobool

Convert the input to a boolean.

Syntax

tobool(value)

Parameters

Prop

Type

Returns: bool

Examples

Example 1

print tobool(1)
print_0 (bool)
true

Example 2

print tobool("true")
print_0 (bool)
true

On this page