> For the complete documentation index, see [llms.txt](https://trizen.gitbook.io/sidef-lang/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://trizen.gitbook.io/sidef-lang/programming_tasks/b/boolean_values.md).

# Boolean values

Sidef defines the *true* and *false* boolean values, which are part of the *Bool* type.

```ruby
var t = true
var f = false
```

In conditional expressions, anything that evaluates to zero or nothing is considered *false*, including empty arrays and empty hashes.

```ruby
if (0 || "0" || false || nil || "" || [] || :()) {
    say "true"
} else {
    say "false"
}
```

#### Output:

```
false
```
